Trying to run a Needle build offline on PCs without internet and I am finding they have this error, how can this be avoided?
GET https://www.gstatic.com/draco/versioned/decoders/1.4.1/draco_decoder.js net::ERR_NAME_NOT_RESOLVED
Original Post on Discord
by user 103054507105067008
For this I searched all .js files in the build for any mentions of
https://www.gstatic.com
This ended up with me having
ck = "/include/draco/",
lk = "/include/ktx2/";
by user 103054507105067008
How do I add that component in my scene?
by user 103054507105067008
Or some example of how to set that, from the docs Iβm not sure where those values are set, is it somehow inside the Needle Engine block in index.hmtl/app.tsx here:
<needle-engine>
</needle-engine>
like this?:
<needle-engine>
dracoDecoderPath = "/include/draco/", ktx2DecoderPath = "/include/ktx/"
</needle-engine>
by user 103054507105067008
@Marcel_Wiessler1
This isnβt working with the React template, I have tried setting those values in App.tsx here in both places and they donβt seem to apply?

by user 103054507105067008
Thing is, the custom loading screen part works fine
by user 103054507105067008
For some reason in the React build when I change out the Draco loader path and ktx2 paths to local, I get this error in the build running offline
THREE.DRACOLoader: Unexpected geometry type
by user 103054507105067008
Sorry i didnt read your code above precisely enough: the draco etc Attributes must be before the closing >. They are html attributes on the component (<needle-engine draco........ >
) the same way like for example a src attribute
<needle-engine dracoDecoderPath="/include/draco/" ktx2DecoderPath="/include/ktx/">
</needle-engine>
When using that. I get βGET http://localhost:5500/include/draco/draco_wasm_wrapper.js 404 (Not Found)β
by user 103054507105067008
Seems like we currently ship outdated draco files. Please replace them with these in your include folder

Testing now
by user 103054507105067008
With those I get these
by user 103054507105067008
When running offline on Live Server
by user 103054507105067008
Are you sure you replaced all of them? I get this error when I just copy the wasm_wrapper. You need to update the decoder.js and decoder.wasm as well.
Might be the build caching one
by user 103054507105067008
I still get these when I check they are properly overwritten, testing while offline with no internet access
by user 103054507105067008