diff --git a/showbits-thermal-printer-ui/tsconfig.app.json b/showbits-thermal-printer-ui/tsconfig.app.json index 246f227..ddaf152 100644 --- a/showbits-thermal-printer-ui/tsconfig.app.json +++ b/showbits-thermal-printer-ui/tsconfig.app.json @@ -1,16 +1,8 @@ { - "extends": "@vue/tsconfig/tsconfig.dom.json", + "extends": ["@vue/tsconfig/tsconfig.dom.json", "./tsconfig.lint.json"], "compilerOptions": { "tsBuildInfoFile": "./node_modules/.tmp/tsconfig.app.tsbuildinfo", - - "paths": { "@/*": ["./src/*"] }, - - /* Linting */ - "strict": true, - "noUnusedLocals": true, - "noUnusedParameters": true, - "noFallthroughCasesInSwitch": true, - "noUncheckedSideEffectImports": true + "paths": { "@/*": ["./src/*"] } }, "include": ["src/**/*.ts", "src/**/*.tsx", "src/**/*.vue"] } diff --git a/showbits-thermal-printer-ui/tsconfig.lint.json b/showbits-thermal-printer-ui/tsconfig.lint.json new file mode 100644 index 0000000..52eb9a4 --- /dev/null +++ b/showbits-thermal-printer-ui/tsconfig.lint.json @@ -0,0 +1,14 @@ +// https://www.typescriptlang.org/tsconfig/ +{ + "compilerOptions": { + // Type Checking + "noFallthroughCasesInSwitch": true, + "noImplicitOverride": true, + "noPropertyAccessFromIndexSignature": true, + "noUncheckedIndexedAccess": true, + "noUncheckedSideEffectImports": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "strict": true + } +} diff --git a/showbits-thermal-printer-ui/tsconfig.node.json b/showbits-thermal-printer-ui/tsconfig.node.json index db0becc..5d56af0 100644 --- a/showbits-thermal-printer-ui/tsconfig.node.json +++ b/showbits-thermal-printer-ui/tsconfig.node.json @@ -1,4 +1,5 @@ { + "extends": "./tsconfig.lint.json", "compilerOptions": { "tsBuildInfoFile": "./node_modules/.tmp/tsconfig.node.tsbuildinfo", "target": "ES2022", @@ -11,14 +12,7 @@ "allowImportingTsExtensions": true, "isolatedModules": true, "moduleDetection": "force", - "noEmit": true, - - /* Linting */ - "strict": true, - "noUnusedLocals": true, - "noUnusedParameters": true, - "noFallthroughCasesInSwitch": true, - "noUncheckedSideEffectImports": true + "noEmit": true }, "include": ["vite.config.ts"] }