Monday, September 9, 2013

jQuery: jquery-1.10.2.min.map is triggering a 404 (Not Found)

"A source map it's a way to map a combined/minified file back to an unbuilt state. When you build for production, along with minifying and combining your JavaScript files, you generate a source map which holds information about your original files. When you query a certain line and column number in your generated JavaScript you can do a lookup in the source map which returns the original location"

So,you have some options:
1. Stop using the .min.js file and use the .js file (recomended for development environmens)
2. Downlad the .map file and add it to your libs: http://jquery.com/download/ Select the option: "Download the map file for jQuery x.xx.x"
3. Delete, from your .min.js file, the  line:
//@ sourceMappingURL=jquery-1.10.2.min.map 

References:
http://stackoverflow.com/questions/18365315/jquerys-jquery-1-10-2-min-map-is-triggering-a-404-not-found
http://www.html5rocks.com/en/tutorials/developertools/sourcemaps/

No comments: