diff --git a/package.json b/package.json index 3b3571e..47bcea8 100644 --- a/package.json +++ b/package.json @@ -8,6 +8,7 @@ "dev:admin": "vite --port 5174 --mode admin", "build": "vite build", "build:admin": "vite build --mode admin", + "typecheck": "vue-tsc --noEmit -p tsconfig.app.json", "preview": "vite preview", "preview:admin": "vite preview --port 5174 --mode admin" }, diff --git a/tsconfig.app.json b/tsconfig.app.json new file mode 100644 index 0000000..2763896 --- /dev/null +++ b/tsconfig.app.json @@ -0,0 +1,24 @@ +{ + "compilerOptions": { + "target": "ES2022", + "useDefineForClassFields": true, + "module": "ESNext", + "lib": ["ES2022", "DOM", "DOM.Iterable"], + "skipLibCheck": true, + "moduleResolution": "bundler", + "allowImportingTsExtensions": true, + "isolatedModules": true, + "moduleDetection": "force", + "noEmit": true, + "strict": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "noFallthroughCasesInSwitch": true, + "jsx": "preserve", + "paths": { + "@/*": ["./src/*"] + } + }, + "include": ["src/**/*.ts", "src/**/*.tsx", "src/**/*.vue"], + "exclude": ["dist", "dist-admin", "node_modules"] +} diff --git a/tsconfig.json b/tsconfig.json index a110e53..1ffef60 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,22 +1,7 @@ { - "compilerOptions": { - "target": "ES2022", - "useDefineForClassFields": true, - "module": "ESNext", - "lib": ["ES2022", "DOM", "DOM.Iterable"], - "skipLibCheck": true, - "moduleResolution": "bundler", - "allowImportingTsExtensions": true, - "isolatedModules": true, - "moduleDetection": "force", - "noEmit": true, - "strict": true, - "noUnusedLocals": true, - "noUnusedParameters": true, - "noFallthroughCasesInSwitch": true, - "paths": { - "@/*": ["./src/*"] - } - }, - "include": ["src/**/*.ts", "src/**/*.tsx", "src/**/*.vue"] + "files": [], + "references": [ + { "path": "./tsconfig.app.json" }, + { "path": "./tsconfig.node.json" } + ] } diff --git a/tsconfig.node.json b/tsconfig.node.json new file mode 100644 index 0000000..27c385f --- /dev/null +++ b/tsconfig.node.json @@ -0,0 +1,12 @@ +{ + "compilerOptions": { + "target": "ES2022", + "lib": ["ES2023"], + "module": "ESNext", + "skipLibCheck": true, + "moduleResolution": "bundler", + "noEmit": true, + "strict": true + }, + "include": ["vite.config.ts"] +}