Fullcalendar Jquery-1.9+.min.map 404 (Not Found) error, Understanding source Map

Source: Internet
Author: User

When you open a page that introduces a jquery script, the error "GET Http://localhost/libs/jquery.min.map 404 (Not Found)" is reported in Chrome's console.

At first I thought it was a bug caused by the chrome installation plug-in, but when we switched the introduction to the jquery development version, the error disappeared. And only Chrome will have this error message, FireFox, IE will not error.

It turned out to be a curse in the jquery script " //@ sourceMappingURL=jquery-1.10.2.min.map ".

If it is arranged in a production environment, you can delete the above line of code directly.

If you are in a development environment, you should download the Jquery-1.10.2.min.map file and put it in the jquery sibling directory (you need the corresponding source map file).

If you want to turn off the error message, you can also uncheck enable source maps in Chrome's developer tools setting.

Why does the code that is commented out of this line work? Then you need to know what the source Map is.

What is source Map

The Source map is a JSON-formatted information file that stores the location information. In other words, it is a dictionary file that is compressed after JS. With it, when it goes wrong, the debugging tool will display the original code directly, not the compressed code. This undoubtedly brings great convenience to the developers.

Because it is a Google custom rule, only browsers based on chromium development support this feature for the time being.

Source Map Generation Tool

Closure compiler

Reference links
    • Introduction to JavaScript Source Maps
    • jquery Official Interpretation
    • JavaScript Source Map Detailed

Transfer from http://www.vipaq.com/Article/View/blog/357.html

Fullcalendar Jquery-1.9+.min.map 404 (Not Found) error, Understanding source Map

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.