From e036686d33383b8996ce47dbd5866155ec332d18 Mon Sep 17 00:00:00 2001 From: Marco Pasqualetti Date: Sun, 23 Feb 2025 15:04:36 +0100 Subject: [PATCH] refactor(examples): uniform `tsconfig.json` files --- examples/tuono-app/tsconfig.json | 35 ++++++++++++++++----------- examples/tuono-tutorial/tsconfig.json | 29 +++++++++++----------- examples/with-mdx/tsconfig.json | 35 ++++++++++++++++----------- examples/with-tailwind/tsconfig.json | 35 ++++++++++++++++----------- 4 files changed, 78 insertions(+), 56 deletions(-) diff --git a/examples/tuono-app/tsconfig.json b/examples/tuono-app/tsconfig.json index e1bbce25..aeced3d3 100644 --- a/examples/tuono-app/tsconfig.json +++ b/examples/tuono-app/tsconfig.json @@ -1,25 +1,32 @@ { "compilerOptions": { - "target": "ES2020", - "useDefineForClassFields": true, - "lib": ["ES2020", "DOM", "DOM.Iterable"], - "module": "ESNext", - "skipLibCheck": true, - "types": ["tuono/build-client"], + // Typechecking + "strict": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "noFallthroughCasesInSwitch": true, - /* Bundler mode */ + // Modules + "module": "ESNext", "moduleResolution": "bundler", - "allowImportingTsExtensions": true, "resolveJsonModule": true, + "allowImportingTsExtensions": true, + "types": ["tuono/build-client"], + + // Interop Constraints "isolatedModules": true, - "noEmit": true, + + // Language and Environment + "target": "ES2020", + "lib": ["ES2020", "DOM", "DOM.Iterable"], + "useDefineForClassFields": true, "jsx": "react-jsx", - /* Linting */ - "strict": true, - "noUnusedLocals": true, - "noUnusedParameters": true, - "noFallthroughCasesInSwitch": true + // Emit + "noEmit": true, + + // Completeness + "skipLibCheck": true }, "include": ["src", "tuono.config.ts"] } diff --git a/examples/tuono-tutorial/tsconfig.json b/examples/tuono-tutorial/tsconfig.json index 0a483ca5..aeced3d3 100644 --- a/examples/tuono-tutorial/tsconfig.json +++ b/examples/tuono-tutorial/tsconfig.json @@ -1,28 +1,29 @@ { "compilerOptions": { - // Language and Environment - "target": "ES2020", - "lib": ["ES2020", "DOM", "DOM.Iterable"], - "jsx": "react-jsx", - "useDefineForClassFields": true, - "types": ["tuono/build-client"], + // Typechecking + "strict": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "noFallthroughCasesInSwitch": true, // Modules "module": "ESNext", "moduleResolution": "bundler", "resolveJsonModule": true, - - // Emit - "noEmit": true, + "allowImportingTsExtensions": true, + "types": ["tuono/build-client"], // Interop Constraints "isolatedModules": true, - // Typechecking - "strict": true, - "noUnusedLocals": true, - "noUnusedParameters": true, - "noFallthroughCasesInSwitch": true, + // Language and Environment + "target": "ES2020", + "lib": ["ES2020", "DOM", "DOM.Iterable"], + "useDefineForClassFields": true, + "jsx": "react-jsx", + + // Emit + "noEmit": true, // Completeness "skipLibCheck": true diff --git a/examples/with-mdx/tsconfig.json b/examples/with-mdx/tsconfig.json index e1bbce25..aeced3d3 100644 --- a/examples/with-mdx/tsconfig.json +++ b/examples/with-mdx/tsconfig.json @@ -1,25 +1,32 @@ { "compilerOptions": { - "target": "ES2020", - "useDefineForClassFields": true, - "lib": ["ES2020", "DOM", "DOM.Iterable"], - "module": "ESNext", - "skipLibCheck": true, - "types": ["tuono/build-client"], + // Typechecking + "strict": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "noFallthroughCasesInSwitch": true, - /* Bundler mode */ + // Modules + "module": "ESNext", "moduleResolution": "bundler", - "allowImportingTsExtensions": true, "resolveJsonModule": true, + "allowImportingTsExtensions": true, + "types": ["tuono/build-client"], + + // Interop Constraints "isolatedModules": true, - "noEmit": true, + + // Language and Environment + "target": "ES2020", + "lib": ["ES2020", "DOM", "DOM.Iterable"], + "useDefineForClassFields": true, "jsx": "react-jsx", - /* Linting */ - "strict": true, - "noUnusedLocals": true, - "noUnusedParameters": true, - "noFallthroughCasesInSwitch": true + // Emit + "noEmit": true, + + // Completeness + "skipLibCheck": true }, "include": ["src", "tuono.config.ts"] } diff --git a/examples/with-tailwind/tsconfig.json b/examples/with-tailwind/tsconfig.json index e1bbce25..aeced3d3 100644 --- a/examples/with-tailwind/tsconfig.json +++ b/examples/with-tailwind/tsconfig.json @@ -1,25 +1,32 @@ { "compilerOptions": { - "target": "ES2020", - "useDefineForClassFields": true, - "lib": ["ES2020", "DOM", "DOM.Iterable"], - "module": "ESNext", - "skipLibCheck": true, - "types": ["tuono/build-client"], + // Typechecking + "strict": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "noFallthroughCasesInSwitch": true, - /* Bundler mode */ + // Modules + "module": "ESNext", "moduleResolution": "bundler", - "allowImportingTsExtensions": true, "resolveJsonModule": true, + "allowImportingTsExtensions": true, + "types": ["tuono/build-client"], + + // Interop Constraints "isolatedModules": true, - "noEmit": true, + + // Language and Environment + "target": "ES2020", + "lib": ["ES2020", "DOM", "DOM.Iterable"], + "useDefineForClassFields": true, "jsx": "react-jsx", - /* Linting */ - "strict": true, - "noUnusedLocals": true, - "noUnusedParameters": true, - "noFallthroughCasesInSwitch": true + // Emit + "noEmit": true, + + // Completeness + "skipLibCheck": true }, "include": ["src", "tuono.config.ts"] }