Fix locales being not linted

This commit is contained in:
wvffle 2022-11-25 19:48:39 +00:00 committed by Kasper Seweryn
parent 5c833da34d
commit 6a6862dbc1
30 changed files with 37 additions and 31 deletions

View File

@ -4,8 +4,8 @@ module.exports = {
es6: true
},
extends: [
'plugin:vue/vue3-recommended',
'plugin:@intlify/vue-i18n/recommended',
'plugin:vue/vue3-recommended',
'@vue/typescript/recommended',
'@vue/standard'
],
@ -37,6 +37,7 @@ module.exports = {
'@intlify/vue-i18n/valid-message-syntax': 'error',
'@intlify/vue-i18n/no-missing-keys': 'error',
'@intlify/vue-i18n/no-dynamic-keys': 'error',
'@intlify/vue-i18n/no-unused-keys': 'error',
// TODO (wvffle): Remove after VUI and #1618
'vue/multi-word-component-names': 'off',
@ -56,11 +57,15 @@ module.exports = {
// brings <!-- eslint-disable --> comments support for the <template> tag in SFCs
'vue/comment-directive': 'off'
}
},
{
files: ['*.json'],
parser: 'jsonc-eslint-parser'
}
],
settings: {
'vue-i18n': {
localeDir: 'src/locales/*.{json,json5,yaml,yml}',
localeDir: './src/locales/*.json',
messageSyntaxVersion: '^9.0.0'
}
}

View File

@ -11,7 +11,7 @@
"serve": "vite preview",
"test": "vitest run",
"test:unit": "vitest run",
"lint": "eslint --ext .ts,.js,.vue,.html src public/embed.html",
"lint": "eslint --ext .ts,.js,.vue,.json,.html src public/embed.html",
"lint:tsc": "vue-tsc --noEmit",
"fix-fomantic-css": "scripts/fix-fomantic-css.sh",
"postinstall": "yarn run fix-fomantic-css"
@ -86,6 +86,7 @@
"eslint-plugin-promise": "6.1.1",
"eslint-plugin-vue": "9.8.0",
"jsdom": "20.0.3",
"jsonc-eslint-parser": "2.1.0",
"moxios": "0.4.0",
"sass": "1.56.1",
"sinon": "14.0.2",

View File

@ -3936,7 +3936,7 @@ jsonc-eslint-parser@^1.0.1:
espree "^6.0.0"
semver "^6.3.0"
jsonc-eslint-parser@^2.0.0:
jsonc-eslint-parser@^2.0.0, jsonc-eslint-parser@^2.1.0:
version "2.1.0"
resolved "https://registry.yarnpkg.com/jsonc-eslint-parser/-/jsonc-eslint-parser-2.1.0.tgz#4c126b530aa583d85308d0b3041ff81ce402bbb2"
integrity sha512-qCRJWlbP2v6HbmKW7R3lFbeiVWHo+oMJ0j+MizwvauqnCV/EvtAeEeuCgoc/ErtsuoKgYB8U4Ih8AxJbXoE6/g==