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
Currently our project has multiple js files in multiple folders, so we are using dynamic file selection in our uglify process and sourcemaps creation for debugging.
When we load the js along the page (using the common script tag at the header), the sourcemaps works properly, but when we load them by ajax it gives an 404 error.
That is because the sourceMappingURL of the js files are relative to the minified files and not the full path from root, so when the file is ajax loaded, it tries to load them from the document url which is wrong.
I think the best way to overcome this error is specifying the full path in the sourcemaps, but as the files are selected dynamically we cannot specify the path of any of them using sourcemaproot, and it isn't any method to specify it dynamically.
The text was updated successfully, but these errors were encountered:
Hi all,
Currently our project has multiple js files in multiple folders, so we are using dynamic file selection in our uglify process and sourcemaps creation for debugging.
Our uglify task is the following:
When we load the js along the page (using the common script tag at the header), the sourcemaps works properly, but when we load them by ajax it gives an 404 error.
That is because the sourceMappingURL of the js files are relative to the minified files and not the full path from root, so when the file is ajax loaded, it tries to load them from the document url which is wrong.
I think the best way to overcome this error is specifying the full path in the sourcemaps, but as the files are selected dynamically we cannot specify the path of any of them using sourcemaproot, and it isn't any method to specify it dynamically.
The text was updated successfully, but these errors were encountered: