-
-
Notifications
You must be signed in to change notification settings - Fork 117
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
Fix sources in source maps #37
Comments
@lihaoyi This project doesn't have any Git tags (which I was going to use in the source map URL). Are you not tagging or have you just not pushed the tags via |
I haven't been tagging my git versions =< I've been lazy and just leaving the versions as commit messages. I assume you want git tags because you can get construct a URL on github which points to a particular tag? |
Bingo. I closed a similar request for scalajs-react with japgolly/scalajs-react@1541a16 and was going to do the same here, then realised no tags. |
Hmm ok, I guess I could publish a new version properly tagged and redirect the source maps at the same time |
I find that way to be the easiest. Added bonus is that Github will recognise the tags as releases whereas for scalatags github currently says "0 releases". Git also allows you to apply tags retrospectively so you can still tag those past releases if you so wish. |
Here's slightly different method. Just added this for Scalaz.js. |
Dude, I just upgrade Chrome (to 38.0.2125.101) and it seems they've added source map validation. Just loading a page now gets my JS console spammed with:
|
oops =/ Is this the kind of thing you can create a PR for? I've been busy with work and haven't had time to come back to this |
If you want-to/can send a PR with a fix, I'll happily take it ^_^ |
Yeah, no worries. For the PR to effective though, you'll need to start tagging and pushing the tags. |
Btw I just followed what seemed to be the norm for the tagging format, which is |
I just published 0.4.2 which should be published with the corrected source maps, but is otherwise identical to 0.4.1. Try it out and feel free to reopen if it doesn't work =) |
Will do. Thanks! On 10 October 2014 14:40, Li Haoyi notifications@github.com wrote:
|
@lihaoyi It appears you forgot to push the |
Just tested this and can confirm: The source maps are pointing to github instead of spamming console. Great. Just need to push that tag and we're done. |
Oops, I think I just pushed the tag, try again? |
Bad news, it seems that GitHub doesn't follow symlinks so everything under The source map tries to access: As sourcemaps are only needed for JS, a hacky workaround would be to make |
@japgolly I tried the "/js/shared is the real thing, /jvm/shared is symlink, remove /shared" thing and updated the |
That's fixed it. Works perfectly now. Thanks Haoyi!~ |
When using source maps with scalatags, it produces sources which are local to the computer where it has been compiled.
I first opened an issue in scala-js, thinking it was a compiler's issue. The available fix is explained in there: scala-js/scala-js#993
The text was updated successfully, but these errors were encountered: