Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Resolve sourceMappingURLs relative to the JS file #19

Closed
danvk opened this issue Oct 23, 2015 · 0 comments
Closed

Resolve sourceMappingURLs relative to the JS file #19

danvk opened this issue Oct 23, 2015 · 0 comments

Comments

@danvk
Copy link
Owner

danvk commented Oct 23, 2015

If source-map-explorer finds a path to the map file in the JS file, it will try to read it relative to the current directory. Instead, it should read it relative to the JS file's directory:

$ tail -1 dist/dygraph-combined.js
//# sourceMappingURL=dygraph-combined.js.map

$ source-map-explorer dist/dygraph-combined.js
/Users/danvk/github/dygraphs/node_modules/source-map-explorer/node_modules/convert-source-map/index.js:31
    throw new Error('An error occurred while trying to read the map file at '
          ^
Error: An error occurred while trying to read the map file at dygraph-combined.js.map
Error: ENOENT, no such file or directory 'dygraph-combined.js.map'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant