0
votes

Is there a way to export the project unbundled? I have a javascript error that happens in the prod environment but not in Dev and it would be nice to be able to debug human readable javascript/typescript instead of the uglified bundled code.

I'm using the jspm/gulp/typescript skeleton.

1
I'm guessing you're using one of the JSPM based skeletons? - Ashley Grant
Yes. Sorry, forgot to mention that. I'll add it to the question. - Bitfiddler
I'm playing with this. It might help to add the SystemJS and JSPM tags to the question. Under the covers, all the aurelia bundler does is call the System Builder API. I'm getting some strange results though when I try to enable source maps - Ashley Grant

1 Answers

1
votes

Here is a temporary answer, that I'm not exactly happy with... Mainly because things aren't working how they should.

If you add "sourceMaps": 'inline' to the options listed in build/bundles.js AND ALSO copy the src folder over to the export folder, then you should get some sourcemap support. It doesn't seem to be working completely though for me, but it might be good enough to work with.

The fact that I tell the bundler to put the sourcemaps inline (and when I base64 decode the sourcemap it seems it is actually inline) but then I still have to add the contents of src directory to make it work doesn't seem right.

It'll look something like this:

enter image description here

I'm not sure if the issue is on the Aurelia side or the System Builder side though.