Vite > ~b24 not resolving BabylonJS imports anymore... what's going on here? #1805
-
Minimal reproduction here: I was developing a nifty Vue 3 app under Vite that used BabylonJS to create a VR environment. Cool stuff. Got everything working, but I haven't worked on it in a week or two (?), came back, updated dependencies, and all hell broke loose. I'm getting weird errors everywhere that seem to suggest that BabylonJS isn't able to find deeper dependencies within the classes I'm using. I had some minor trouble with this before, but figured out how to work around it. Now it's back, and far worse. Even creating a universal camera throws an error about gamepads (which are not an input device on my machine). I believe the break point happened soon around/with the addition of the Vue Vite plugin, since that's one line of code I had to change (adding the Vue plugin for Vite) to make things start up again after the dependency updates. Any help would be appreciated! I love Vue, Vite, and BabylonJS, so I definitely want to figure out how to make them play nice together. BabylonJS's ES build is, from what I gather, a bit "weird," which is likely contributing to this issue. Here's their documentation, I haven't found anything magical in there yet to resolve the problem (or searching for similar issues in the forum): https://doc.babylonjs.com/divingDeeper/developWithBjs/treeShaking#faq |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
This is fixed in 8e1d3d8, should be working in next release. |
Beta Was this translation helpful? Give feedback.
This is fixed in 8e1d3d8, should be working in next release.