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

404 ...foo.js.map not found #1003

Closed
ghost opened this issue Aug 9, 2015 · 3 comments
Closed

404 ...foo.js.map not found #1003

ghost opened this issue Aug 9, 2015 · 3 comments

Comments

@ghost
Copy link

ghost commented Aug 9, 2015

Running jspm@beta with an app with two files:
1(main.js) import './test';
2(test.js) console.log('here');

screen shot 2015-08-09 at 11 15 09 am

I don't notice this in Chrome, and everything else works fine, but it might be confusing for new adopters of jspm.

@guybedford
Copy link
Member

Which browser are you getting this in?

@ghost
Copy link
Author

ghost commented Aug 11, 2015

Sorry, that is in Safari Version 9.0 (11601.1.43)
I think it might be coming from browser.js in babel because I noticed this will trying to use it without JSPM after I filed this issue.

@guybedford
Copy link
Member

Yes, it seems it is due to this line in Babel:

var mapFileCommentRx =
  // //# sourceMappingURL=foo.js.map                       
  /(?:\/\/[@#][ \t]+sourceMappingURL=([^\s'"]+?)[ \t]*$)|(?:\/\*[@#][ \t]+sourceMappingURL=([^\*]+?)[ \t]*(?:\*\/){1}[ \t]*$)/mg

Which is being detected not as a regex but as a sourceURL comment in Safari.

It's a Babel thing / Safari bug. It may be worth mentioning on Babel's issue queue if they don't already know about it.

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