-
Notifications
You must be signed in to change notification settings - Fork 9.3k
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
core: update SourceMap build to use newest frontend and ParsedURL #14108
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
connorjclark
commented
Jun 9, 2022
@@ -133,7 +133,7 @@ class UnusedJavaScript extends ByteEfficiencyAudit { | |||
}) | |||
.filter(d => d.unused >= bundleSourceUnusedThreshold); | |||
|
|||
const commonSourcePrefix = commonPrefix([...bundle.map.sourceInfos.keys()]); | |||
const commonSourcePrefix = commonPrefix(bundle.map.sourceURLs()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
literally does the same thing
connorjclark
commented
Jun 9, 2022
@@ -100,7 +100,7 @@ class ModuleDuplication { | |||
for (let i = 0; i < rawMap.sources.length; i++) { | |||
if (this._shouldIgnoreSource(rawMap.sources[i])) continue; | |||
|
|||
const sourceKey = (rawMap.sourceRoot || '') + rawMap.sources[i]; | |||
const sourceKey = rawMap.sources[i]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks like the sourceRoot is no longer used to index the sources
array.
connorjclark
commented
Jun 9, 2022
brendankenny
reviewed
Jun 9, 2022
connorjclark
changed the title
core: update cdt SourceMap to latest devtools frontend
core: update SourceMap build to use newest frontend, and use ParsedURL
Jun 9, 2022
connorjclark
changed the title
core: update SourceMap build to use newest frontend, and use ParsedURL
core: update SourceMap build to use newest frontend and ParsedURL
Jun 9, 2022
adamraine
approved these changes
Jun 22, 2022
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.
There's a handful of what seems like useful fixes since we last updated. see the history.
Since our last update, the CDT build has changed quite a bit. Including private fields. So we get some cruft in our outputted SourceMap.js now.
I tweaked the build script to do the raw string replacements on the input, instead of the code output. It made it simpler to iterate.