-
Notifications
You must be signed in to change notification settings - Fork 21
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
produced sourcemap seems to have wrong mapping #38
Comments
Hmm from just briefly looking at the code it looks like it may be expected behaviour. Since the css is concatenated before passing to gulp-bless, so the mapping is based on the concatenated css. But I may be wrong, I will have to look further. |
I thought that might be the case too but actually the mapping somehow outputs correctly, despite concatenation, based on the original sass (if bless isn't included) |
@entozoon So I was wrong. I thought it's expected behaviour based on the existing code (I'm new to all the source mapping stuff). After researching source mapping a little bit more, I figured that the "expected behaviour" is actually wrong, the mapping should map all the way back to the original file that a coder wrote, not some intermediated compiled source. So yea your right, thanks for reporting this issue! I learn something new from it. Like before can you try it out using the branch I will work on releasing the fix as a major version bump release (so 4.0.0); this change is quite bit so I will need to get some feedback from the creator of this project, so I may not be able to do a release as fast as last time. However, as usual, I will comment on this ticket when I release this fix. |
@alvinlin123 great fix, thanks! |
4.0.0 released with the fix. Thanks! 😁 |
Thanks Adam! |
The issue-38-fix branch was deleted. If I was using that, is the 4.0.0 release identical, or are there other concerns with it, being a major update and all? |
@charginghawk Yup 4.0.0 is identical to issue-38-fix branch. The major version was bumped because the fix introduces some backward incompatibility. |
This is an follow up issue of #36
Below is @entozoon's original words:
I've looked closer at our test repo (forked here:)
https://github.com/entozoon/gulp-bless-issue36-sample
And although it is outputting sourcemap data, it's actually wrong.
If you look at the index.html and inspect element (chrome with sourcemaps enabled) you can see that it shows the css properties line numbers in the compiled css file, rather than their source sass files.
e.g. in this repo, stuff like:
But without using bless in the gulpfile, it shows the proper output of:
Sorry for pointing it out and, again i'm not sure if it's gulp-bless or gulp-sourcemaps.. or the gulpfile ordering itself that's the issue.
I can alternate between using either sourcemaps/bless separately in dev/production so it's not a bother :)
The text was updated successfully, but these errors were encountered: