Skip to content

fix(css): link sourcemap with source correctly #140

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

Merged
merged 2 commits into from
Oct 19, 2020
Merged

Conversation

lukeed
Copy link
Member

@lukeed lukeed commented Oct 19, 2020

Previously, a assets/bundle.css was including this:

/*# sourceMappingURL=assets/bundle.css.map */

This resolved in an incorrect sourcemap since when resolved from assets/bundle.css, this would produce a request to assets/assets/bundle.css.map.

This was also true for the "file" key inside the sourcemap itself.

Both locations now relatively-resolve to one another. AKA, if writing to an assets directory (Rollup default) then the output files will not include the assets/ prefix when referencing one another.

@lukeed lukeed requested review from benmccann and pngwn October 19, 2020 22:27
@lukeed
Copy link
Member Author

lukeed commented Oct 19, 2020

Ty sir

@lukeed lukeed merged commit 113db9a into master Oct 19, 2020
@lukeed lukeed deleted the fix/sourcemap branch October 19, 2020 22:41
@lukeed lukeed mentioned this pull request Oct 22, 2020
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

Successfully merging this pull request may close these issues.

2 participants