[Solved-4 Solutions] jQuery's jquery-1.10.2.min.map is triggering a 404 (Not Found) - javascript tutorial



Problem:

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

Solution 1:

  • Use an uncompressed js file, but the uncompressed js is large, which will affect the transfer speed.
  • Download the min.map file from jquery's official website. Chrome will open the source map download switch by default. For this case, the download amount will be larger than the single compressed js file, and the min.map file download will be created.
  • Create an empty min.map file, named after the min.map file name in the compressed js. In this case, an additional min.map download is created. It is different from the official website download. Generate network link overhead, file transfer overhead can be ignored;
  • The browser ends the download source map choice, the way to cover the entry, the normal chrome user won’t turn off this choice, so it will also alarm.

Solution 2:

Remove the 404 error by removing the line //@ sourceMappingURL=jquery-1.10.2.min.map from the top part of your jQuery file.
The top part of the jQuery file will look like this.

/*! jQuery v1.10.2 | (c) 2005, 2013 jQuery Foundation, Inc. | jquery.org/license 
//@ sourceMappingURL=jquery-1.10.2.min.map
*/

Just change that to /*! jQuery v1.10.2 | (c) 2005, 2013 jQuery Foundation, Inc. | jquery.org/license */

Solution 3:

1. Download the map file and the uncompressed version of jQuery. Put them with the minified version:

Map File

Learn javascript - javascript tutorial - mapfile - javascript examples - javascript programs

2. Include minified version into your HTML:

Source Maps

Learn javascript - javascript tutorial - sourcemaps - javascript examples - javascript programs

3. Check in Google Chrome:

js Library

Learn javascript - javascript tutorial - js-library - javascript examples - javascript programs

Solution 4:

Rename jquery-1.9.1.min.map to jquery.min.map



Related Searches to jQuery's jquery-1.10.2.min.map is triggering a 404 (Not Found) - javascript tutorial