From f879bf1bbf49064f1908d89869f7c312374293fd Mon Sep 17 00:00:00 2001 From: Wahyu Budi Saputra Date: Tue, 27 Feb 2024 10:44:44 +0800 Subject: [PATCH 1/5] Removes `node` type because we already have `@remix-run/node` type --- templates/vite-express/tsconfig.json | 2 +- templates/vite/tsconfig.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/templates/vite-express/tsconfig.json b/templates/vite-express/tsconfig.json index b35e152455c..037e5592feb 100644 --- a/templates/vite-express/tsconfig.json +++ b/templates/vite-express/tsconfig.json @@ -2,7 +2,7 @@ "include": ["**/*.ts", "**/*.tsx"], "compilerOptions": { "lib": ["DOM", "DOM.Iterable", "ES2022"], - "types": ["@remix-run/node", "node", "vite/client"], + "types": ["@remix-run/node", "vite/client"], "isolatedModules": true, "esModuleInterop": true, "jsx": "react-jsx", diff --git a/templates/vite/tsconfig.json b/templates/vite/tsconfig.json index b35e152455c..037e5592feb 100644 --- a/templates/vite/tsconfig.json +++ b/templates/vite/tsconfig.json @@ -2,7 +2,7 @@ "include": ["**/*.ts", "**/*.tsx"], "compilerOptions": { "lib": ["DOM", "DOM.Iterable", "ES2022"], - "types": ["@remix-run/node", "node", "vite/client"], + "types": ["@remix-run/node", "vite/client"], "isolatedModules": true, "esModuleInterop": true, "jsx": "react-jsx", From 680840cc249f8fb064d79f100f3266f8797c1c25 Mon Sep 17 00:00:00 2001 From: Wahyu Budi Saputra Date: Tue, 27 Feb 2024 10:45:22 +0800 Subject: [PATCH 2/5] Adding `.server` modules on the `include` field of tsconfig --- templates/vite-cloudflare/tsconfig.json | 2 +- templates/vite-express/tsconfig.json | 2 +- templates/vite/tsconfig.json | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/templates/vite-cloudflare/tsconfig.json b/templates/vite-cloudflare/tsconfig.json index 7e1ead6353b..4b2f28748de 100644 --- a/templates/vite-cloudflare/tsconfig.json +++ b/templates/vite-cloudflare/tsconfig.json @@ -1,5 +1,5 @@ { - "include": ["**/*.ts", "**/*.tsx"], + "include": ["**/*.ts", "**/*.tsx", "**/.server/**/*.ts"], "compilerOptions": { "lib": ["DOM", "DOM.Iterable", "ES2022"], "types": ["@remix-run/cloudflare", "vite/client"], diff --git a/templates/vite-express/tsconfig.json b/templates/vite-express/tsconfig.json index 037e5592feb..790caab83bf 100644 --- a/templates/vite-express/tsconfig.json +++ b/templates/vite-express/tsconfig.json @@ -1,5 +1,5 @@ { - "include": ["**/*.ts", "**/*.tsx"], + "include": ["**/*.ts", "**/*.tsx", "**/.server/**/*.ts"], "compilerOptions": { "lib": ["DOM", "DOM.Iterable", "ES2022"], "types": ["@remix-run/node", "vite/client"], diff --git a/templates/vite/tsconfig.json b/templates/vite/tsconfig.json index 037e5592feb..790caab83bf 100644 --- a/templates/vite/tsconfig.json +++ b/templates/vite/tsconfig.json @@ -1,5 +1,5 @@ { - "include": ["**/*.ts", "**/*.tsx"], + "include": ["**/*.ts", "**/*.tsx", "**/.server/**/*.ts"], "compilerOptions": { "lib": ["DOM", "DOM.Iterable", "ES2022"], "types": ["@remix-run/node", "vite/client"], From abee2ee9697a8a00fc8383d532ffa94960605f3a Mon Sep 17 00:00:00 2001 From: Wahyu Budi Saputra Date: Tue, 27 Feb 2024 10:55:24 +0800 Subject: [PATCH 3/5] Adding myself to the contributor list --- contributors.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/contributors.yml b/contributors.yml index 6c1570dbd32..b1594c454da 100644 --- a/contributors.yml +++ b/contributors.yml @@ -628,6 +628,7 @@ - vm - vmosyaykin - vorcigernix +- wahyubucil - wangbinyq - weavdale - wilcoschoneveld From 195786fbb9607d642458a4d18e3d3eb9794dd3be Mon Sep 17 00:00:00 2001 From: Wahyu Budi Saputra Date: Tue, 27 Feb 2024 11:44:34 +0800 Subject: [PATCH 4/5] Revert the `node` type removal --- templates/vite-express/tsconfig.json | 2 +- templates/vite/tsconfig.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/templates/vite-express/tsconfig.json b/templates/vite-express/tsconfig.json index 790caab83bf..b16686b830e 100644 --- a/templates/vite-express/tsconfig.json +++ b/templates/vite-express/tsconfig.json @@ -2,7 +2,7 @@ "include": ["**/*.ts", "**/*.tsx", "**/.server/**/*.ts"], "compilerOptions": { "lib": ["DOM", "DOM.Iterable", "ES2022"], - "types": ["@remix-run/node", "vite/client"], + "types": ["@remix-run/node", "node", "vite/client"], "isolatedModules": true, "esModuleInterop": true, "jsx": "react-jsx", diff --git a/templates/vite/tsconfig.json b/templates/vite/tsconfig.json index 790caab83bf..b16686b830e 100644 --- a/templates/vite/tsconfig.json +++ b/templates/vite/tsconfig.json @@ -2,7 +2,7 @@ "include": ["**/*.ts", "**/*.tsx", "**/.server/**/*.ts"], "compilerOptions": { "lib": ["DOM", "DOM.Iterable", "ES2022"], - "types": ["@remix-run/node", "vite/client"], + "types": ["@remix-run/node", "node", "vite/client"], "isolatedModules": true, "esModuleInterop": true, "jsx": "react-jsx", From 52b32df53c9490b0b4d8b5618bca743d43954675 Mon Sep 17 00:00:00 2001 From: Wahyu Budi Saputra Date: Tue, 27 Feb 2024 11:44:58 +0800 Subject: [PATCH 5/5] Add `.tsx` files and `.client` directories --- templates/vite-cloudflare/tsconfig.json | 9 ++++++++- templates/vite-express/tsconfig.json | 9 ++++++++- templates/vite/tsconfig.json | 9 ++++++++- 3 files changed, 24 insertions(+), 3 deletions(-) diff --git a/templates/vite-cloudflare/tsconfig.json b/templates/vite-cloudflare/tsconfig.json index 4b2f28748de..a61e663a765 100644 --- a/templates/vite-cloudflare/tsconfig.json +++ b/templates/vite-cloudflare/tsconfig.json @@ -1,5 +1,12 @@ { - "include": ["**/*.ts", "**/*.tsx", "**/.server/**/*.ts"], + "include": [ + "**/*.ts", + "**/*.tsx", + "**/.server/**/*.ts", + "**/.server/**/*.tsx", + "**/.client/**/*.ts", + "**/.client/**/*.tsx" + ], "compilerOptions": { "lib": ["DOM", "DOM.Iterable", "ES2022"], "types": ["@remix-run/cloudflare", "vite/client"], diff --git a/templates/vite-express/tsconfig.json b/templates/vite-express/tsconfig.json index b16686b830e..9b51f9667c9 100644 --- a/templates/vite-express/tsconfig.json +++ b/templates/vite-express/tsconfig.json @@ -1,5 +1,12 @@ { - "include": ["**/*.ts", "**/*.tsx", "**/.server/**/*.ts"], + "include": [ + "**/*.ts", + "**/*.tsx", + "**/.server/**/*.ts", + "**/.server/**/*.tsx", + "**/.client/**/*.ts", + "**/.client/**/*.tsx" + ], "compilerOptions": { "lib": ["DOM", "DOM.Iterable", "ES2022"], "types": ["@remix-run/node", "node", "vite/client"], diff --git a/templates/vite/tsconfig.json b/templates/vite/tsconfig.json index b16686b830e..9b51f9667c9 100644 --- a/templates/vite/tsconfig.json +++ b/templates/vite/tsconfig.json @@ -1,5 +1,12 @@ { - "include": ["**/*.ts", "**/*.tsx", "**/.server/**/*.ts"], + "include": [ + "**/*.ts", + "**/*.tsx", + "**/.server/**/*.ts", + "**/.server/**/*.tsx", + "**/.client/**/*.ts", + "**/.client/**/*.tsx" + ], "compilerOptions": { "lib": ["DOM", "DOM.Iterable", "ES2022"], "types": ["@remix-run/node", "node", "vite/client"],