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 am trying to run my ThreeJs App in production, but it fails with: Uncaught TypeError: Failed to construct 'URL': Invalid URL
at the position where I create a link for my skybox background: let skyboxImage = "" + new URL("../assets/textures/AllSkyFree_BlueSunsetSky-min.png", import.meta.url);
On the dev server it works, after production building it does not. But the desired image is output in my build folder.
🐛 bug report
I am trying to run my ThreeJs App in production, but it fails with:
Uncaught TypeError: Failed to construct 'URL': Invalid URL
at the position where I create a link for my skybox background:
let skyboxImage = "" + new URL("../assets/textures/AllSkyFree_BlueSunsetSky-min.png", import.meta.url);
On the dev server it works, after production building it does not. But the desired image is output in my build folder.
🎛 Configuration (package.json)
.parcelrc
🤔 Expected Behavior
Should find the relative URL just like it does in the dev build.
😯 Current Behavior
Error says unvalid url
Uncaught TypeError: Failed to construct 'URL': Invalid URL
Build file:
💁 Possible Solution
I have this texture/image in my assets folder, maybe I should include them in the static file path?
💻 Code Sample
Here the short form of the file:
🌍 Your Environment
The text was updated successfully, but these errors were encountered: