In my project, I work with TypeScript and import Three.js library. But here's the twist - I don't have access to NPM or node-modules.
So, what I did was add custom paths in my ts-config.json
under compilerOptions
.
"paths": {
"three":["./Scripts/three-0.157.0/three.module.js"],
"three/addons/*":["./Scripts/three-0.157.0/jsm/*"]
}
While this setup allows me to compile without errors, VS Code doesn't provide much help in terms of IntelliSense.
I tried updating compilerOptions
by setting "allowJs": true
, which improved IntelliSense but slowed down compilation to a point where tsc
crashed.
So, my question is - am I missing something in my setup? Is there a solution that can give me both fast compilation and helpful IntelliSense in VS Code?