From 2ef8babb6f7f70ebd8f08ee4764d062ad83c29af Mon Sep 17 00:00:00 2001 From: PunGrumpy <108584943+PunGrumpy@users.noreply.github.com> Date: Fri, 23 Oct 2026 00:11:22 +0700 Subject: [PATCH] refactor(web): load the wgsl module types from tsconfig wgsl-env.d.ts held a single triple-slash directive, which is comment syntax carrying real behavior: it gave TypeScript the module declarations for the shader imports. @vgpu/wgsl documents a compilerOptions.types entry as the equivalent setup, so list the package types in tsconfig.json and delete the file. Without the entry, typecheck fails with TS2307 on the three shader imports in the landing store canvas, so the entry is what supplies the types. --- apps/web/tsconfig.json | 1 + apps/web/wgsl-env.d.ts | 1 - 2 files changed, 1 insertion(+), 1 deletion(-) delete mode 100644 apps/web/wgsl-env.d.ts diff --git a/apps/web/tsconfig.json b/apps/web/tsconfig.json index fdf2be1..cf9d15e 100644 --- a/apps/web/tsconfig.json +++ b/apps/web/tsconfig.json @@ -14,6 +14,7 @@ "isolatedModules": true, "jsx": "react-jsx", "incremental": true, + "types": ["@vgpu/wgsl/wgsl-types"], "paths": { "@/*": ["./*"] }, diff --git a/apps/web/wgsl-env.d.ts b/apps/web/wgsl-env.d.ts deleted file mode 100644 index 61dac4f..0000000 --- a/apps/web/wgsl-env.d.ts +++ /dev/null @@ -1 +0,0 @@ -///