-
Notifications
You must be signed in to change notification settings - Fork 798
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
feat(sourcemap): enable rfc-3986 urls #3100
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ensure that sourceMapUrls are compliant with RFC-3986, per the sourcemap [specification](https://sourcemaps.info/spec.html#h.crcf4lqeivt8). Specifically: > Note: <url> is a URL as defined in RFC3986; in particular, characters outside the set permitted to appear in URIs must be percent-encoded. STENCIL-173: Make sourceMapUrl values RFC 3986 compliant
ltm
approved these changes
Oct 11, 2021
splitinfinities
approved these changes
Oct 11, 2021
3 tasks
rwaskiewicz
added a commit
that referenced
this pull request
Dec 1, 2021
this commit fixes a regression originally introduced in #3100, where inline sourcemaps that are data URI's are erroneously encoded using RFC-3986. this causes the sourcemaps for tests to not correctly map the transpiled output back to the original source code.
14 tasks
rwaskiewicz
added a commit
that referenced
this pull request
Dec 2, 2021
this commit fixes a regression originally introduced in #3100, where inline sourcemaps that are data URI's are erroneously encoded using RFC-3986. this causes the sourcemaps for tests to not correctly map the transpiled output back to the original source code.
rwaskiewicz
added a commit
that referenced
this pull request
Dec 3, 2021
this commit fixes a regression originally introduced in #3100, where inline sourcemaps that are data URI's are erroneously encoded using RFC-3986. this causes the sourcemaps for tests to not correctly map the transpiled output back to the original source code.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Pull request checklist
Please check if your PR fulfills the following requirements:
npm run build
) was run locally and any changes were pushednpm test
) were run locally and passednpm run test.karma.prod
) were run locally and passednpm run prettier
) was run locally and passedPull request type
Please check the type of change your PR introduces:
What is the current behavior?
Today, sourcemap urls generated by Stencil work, but are not compliant with the sourcemap spec
GitHub Issue Number: N/A
What is the new behavior?
ensure that sourceMapUrls are compliant with RFC-3986, per the sourcemap
specification:
STENCIL-173: Make sourceMapUrl values RFC 3986 compliant
Does this introduce a breaking change?
Testing
https://github.com/rwaskiewicz/stencil-sourcemap-rfc3986/commits/main demonstrates how I tested this. Looking through the history of that repro:
npm init stencil
for a component librarynpm i
npm ci && npm run build && npm pack
npm i <PATH_TO_TARBALL>
my-component.tsx
to use most of the RFC 3986 chars (omitting the single quote)utils/utils.ts
to use all rfc 2986 charsI then ran
npm start
and validated that sourcemaps look a-okay:Oh, and this is unit tested as well 🙂
Other information