Skip to content

Commit

Permalink
[fix] adjust tsconfig for three module resolution to fix build errors
Browse files Browse the repository at this point in the history
  • Loading branch information
ael-mouz committed May 8, 2024
1 parent 93d5129 commit 5961b58
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 29 deletions.
20 changes: 13 additions & 7 deletions app/front-end/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,30 +1,36 @@
{
"compilerOptions": {
"types": ["three"],
"types": ["three"], // Ensure three is listed here
"lib": ["dom", "dom.iterable", "esnext"],
"allowJs": true,
"skipLibCheck": true,
"strict": true,
"noEmit": true,
"esModuleInterop": true,
"module": "esnext",
"moduleResolution": "bundler",
"moduleResolution": "node", // Changed from "bundler" to "node"
"resolveJsonModule": true,
"isolatedModules": true,
"jsx": "preserve",
"incremental": true,
"tsBuildInfoFile": "./.tsbuildinfo",
// "useDefineForClassFields": true, // JIT mode (if using TypeScript 4.4+)
"tsBuildInfoFile": "./.tsbuildinfo",
"plugins": [
{
"name": "next"
}
],
"paths": {
"@/*": ["./src/*"]
"@/*": ["./src/*"],
"three": ["./node_modules/three/src/Three"] // Make sure this path matches your node_modules structure
}
},
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts", "src/components/BootstrapClient.js", "src/components/bootstrap.tsx"],
// "exclude": ["node_modules"]
"include": [
"next-env.d.ts",
"**/*.ts",
"**/*.tsx",
".next/types/**/*.ts",
"src/components/BootstrapClient.js",
"src/components/bootstrap.tsx"
],
"exclude": ["node_modules", "test", "*.test.ts", "*.spec.ts"]
}
17 changes: 0 additions & 17 deletions package-lock.json

This file was deleted.

5 changes: 0 additions & 5 deletions package.json

This file was deleted.

0 comments on commit 5961b58

Please sign in to comment.