As title states, whenever I deploy my app, the entire three.js project deploys perfectly but my .glb file receives the 404 resource not found error. I’m not sure what the issue is. I’ve tried to change the file path but no success. I am using Vite.js for local running
Github repo - https://github.com/ElijahSchrock/Neo-Runner
Heroku Deploy - https://neo-runner.herokuapp.com/
Here is my create character function
Here is Don McCurdy's take on it from the threejs forum https://discourse.threejs.org/t/when-i-deploy-to-heroku-my-deployment-is-successful-but-my-glb-file-receives-404-error/32750/2
And I am also using the static build pack as well as the nodejs buildpack. please help !! Thank you! :)
There is a tiny issue with your path to the glTF asset. Instead of:
loader.load('./Neo.glb', (gltf) => {
you want to use:
loader.load('./model/Neo.glb', (gltf) => {
this error has been solved by hosting my files on aws s3 and using that object url in my gltf loader. Make sure to set your CORS correctly
Excuse me Mr.Schrock did you run the NPM and make sure to pass the variables through the selective bloom? I'd say using a component in layerville livewire would be your best option. However, I also think that if you call the function into the div, you can use a boolean to make an if else statement. Make sure that you use node to call your react for deployment. Throw some swift elements into the app for your jquery on Heroku or look thru your contributions in the branch.