Source mapping URL not detected although present

#2 · closed · 3 comments

View on GitHub ↗

Synzvato

In some cases, nothing is found by source-map-url, when the source mapping URL is clearly present in the minified resource. Here's an example (a common version of jQuery): https://code.jquery.com/jquery-1.10.1.min.js

Comments

lydell

This module expects the sourceMappingURL to be at the very end of the file. Perhaps that’s wrong.

Synzvato

@lydell The thing is that, in my case, it's not possible to alter the source files. I would like to use this library to find source mapping URLs within a large, ever changing, collection of libraries. Having to prepare the files by hand would defy the purpose of the solution. The undetectable source mapping URLs do work inside of all tested major browsers, so I assume that the notation (URL before last line) is valid. I'd be happy to hear your thoughts on this.

lydell

Well, if it works in every major browser we should support it. PRs welcome.