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

source-map file name with query parameter, causes source-map not found #46

Closed
UncleBill opened this issue Mar 8, 2017 · 3 comments
Closed

Comments

@UncleBill
Copy link

cli output

image

reproduce

Add query parameter to file name in source-map comment. (by my webpack config)

//# sourceMappingURL=app.js.map?85439c
@UncleBill
Copy link
Author

It should be an issue of thlorenz/convert-source-map
index.js#L87-L97 :

    // Try to read a source map from a 'sourceMappingURL' comment.
    var converter = convert.fromSource(jsData);
    if (!converter) {
      converter = convert.fromMapFileSource(jsData, path.dirname(jsFile));
    }
    if (!converter) {
      console.error('Unable to find a source map.');
      console.error('See ', SOURCE_MAP_INFO_URL);
      return null;
    }

@danvk
Copy link
Owner

danvk commented Mar 8, 2017 via email

@UncleBill
Copy link
Author

pass in the path to the source map explicitly as a second CLI parameter

Oh, I almost forgot that! source-map-explor + filename is more convenient. 😄

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

2 participants