I uploaded a .map file for a dependency to have it debuggable in devtools, but glitch always throws it into assets. This fails the source mapping, as it tries to find the original JS files on the CDN origin.
Think this post may explain why they use the asset folder for uploads, and may give you options to use in the mean time…
The why-cdn doesn’t really matter here, JS and source map files need to be together. Just to explain further: Generates JS files point to source map files, which are pointing to original JS files. Uploading the source map file to CDN breaks a) the link from generated to original file as the source map file gets renamed and b) breaks the link from source map to original JS files, as the JS files don’t live on the CDN.
I solved it for now by renaming the source map file to .map.js.
ah I see what you mean now, I guess there is a filter type on the uploads that is sending your map file into the assets. Although I do like glitch the ide has a bit of work to make it more user friendly, but using the git method with a local ide does work quite well, and adding and changing files is a lot easier, but kinda defeats the idea of online development.
If you upload the .map file to the internet somewhere (or even just your assets folder) then get the URL for it and open the console and run
Hey @digitarald, welcome to the Glitch forum!
This is a good point; thanks for posting this! I’m moving it to the Feature Ideas area so folks can vote on it. As other folks have mentioned, there are workarounds in the meantime.