refactor: minor tunes

* Added suggested options to tsconfig.json by Vite docs:
  https://vitejs.dev/guide/features.html#typescript-compiler-options
* Ignore inline comments capitalization
* Add jsonc/auto rule to automatically inherit eslint rules for JSON files
* Improve dpdm run parameters

Signed-off-by: Fernando Fernández <ferferga@hotmail.com>
This commit is contained in:
Fernando Fernández 2023-12-31 17:15:56 +01:00
parent dcf18dc729
commit 757e357ad6
No known key found for this signature in database
GPG Key ID: 82FD36644F1F4D3B
3 changed files with 11 additions and 4 deletions

View File

@ -121,7 +121,12 @@ module.exports = {
'@stylistic/type-named-tuple-spacing': 'error',
'no-extend-native': 'error',
'file-progress/activate': CI_environment,
'capitalized-comments': 'error',
'capitalized-comments': [
'error', 'always',
{
'ignoreInlineComments': true,
ignoreConsecutiveComments: true
}],
'multiline-comment-style': 'error',
'unicode-bom': ['error', 'never'],
'no-restricted-globals': ['error', ...restrictedGlobals],
@ -232,7 +237,8 @@ module.exports = {
parser: 'jsonc-eslint-parser',
rules: {
'@stylistic/quotes': ['error', 'double'],
'@stylistic/semi': 'off'
'@stylistic/semi': 'off',
'jsonc/auto': 'error'
}
},
{

View File

@ -7,7 +7,7 @@
"defaults and supports es6-module"
],
"scripts": {
"analyze": "dpdm --no-warning --no-tree src/main.ts && vite build --mode analyze",
"analyze": "dpdm --no-warning --no-tree src/**/*.{ts,vue} && vite build --mode analyze",
"build": "vite build",
"check": "npm run lint && npm run typecheck",
"start": "vite",

View File

@ -5,10 +5,11 @@
"moduleResolution": "Bundler",
"esModuleInterop": true,
"resolveJsonModule": true,
"allowJs": true,
"sourceMap": true,
"strict": true,
"noEmit": true,
"isolatedModules": true,
"useDefineForClassFields": true,
"noImplicitThis": true,
"noImplicitAny": true,
"experimentalDecorators": true,