You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I ran into this bug and it took a while to figure out. It turns out that this library (as well as threes-stdlib) are not compatible with "NodeNext" module/moduleResolution, e.g. if you tsconfig.json looks like this:
src/Scene.tsx:17:16 - error TS2305: Module '"three-stdlib"' has no exported member 'GLTFLoader'.
You can work around the bug by switching your tsconfig.json to something like this instead:
"module": "ESNext",
"moduleResolution": "Node",
Relevant code:
Included in the above description.
Suggested solution:
I suspect there is some way to fix this? But I do not yet know. One clue is that @react-three/fiber and @react-three.drei work properly with these tsconfig.json settings.
The text was updated successfully, but these errors were encountered:
three
version: n/a@types/three
version: n/athree-stdlib
version: 2.29.4Problem description:
I ran into this bug and it took a while to figure out. It turns out that this library (as well as threes-stdlib) are not compatible with "NodeNext" module/moduleResolution, e.g. if you tsconfig.json looks like this:
And you try to use this library like this:
Code:
You will get compile errors via TSC like this:
You can work around the bug by switching your tsconfig.json to something like this instead:
Relevant code:
Included in the above description.
Suggested solution:
I suspect there is some way to fix this? But I do not yet know. One clue is that @react-three/fiber and @react-three.drei work properly with these tsconfig.json settings.
The text was updated successfully, but these errors were encountered: