-
Notifications
You must be signed in to change notification settings - Fork 44
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 importComponent
#2070
Merged
Merged
Fix importComponent
#2070
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
ZauberNerd
added
📦 master
Apply this label to a pull request, if it has to be cherry-picked to the maste-branch.
📦 v15
Apply this label to a pull request, if it has to be cherry-picked to the v15.x-branch after merging.
labels
Jan 31, 2022
ZauberNerd
force-pushed
the
fix-importcomponent
branch
from
January 31, 2022 17:49
11194bc
to
0592229
Compare
ZauberNerd
force-pushed
the
fix-importcomponent
branch
from
February 2, 2022 11:22
0592229
to
fc844e3
Compare
We observed that in some cases the generated module ids differe between the browser and server build. This happens when one of the builds is able to concatenate modules into one chunk while the other build can't (e.g. because the modules live in different chunks because of code splitting). Because we did not want to split the server build into chunks and then load them manually, we decided to generate stable chunk names, that do not differ between browser/server, in our importComponent babel plugin. We tried to work around this issue previously via #1976 but with a later webpack version our workaround stopped working. Furthermore, our previous workaround had other issues, which impacted tree-shaking and therefore the bundle size. Co-authored-by: Markus Wolf <markus.wolf@new-work.se> Co-authored-by: Philipp Hinrichsen <philipp.hinrichsen@new-work.se> Co-authored-by: Robert Kowalski <robert.kowalski@new-work.se>
In case the `--experimental-esbuild` mode is used, we have a small webpack loader to handle the `importComponent` transformation. This had been introduced in #1632 to be a quick & dirty regex based replacer. With this commit we now have a webpack loader that has a fast-exit path in case `importComponent` is not used. Otherwise it will transpile the source code using the proper babel plugin. Co-authored-by: Markus Wolf <markus.wolf@new-work.se> Co-authored-by: Philipp Hinrichsen <philipp.hinrichsen@new-work.se> Co-authored-by: Robert Kowalski <robert.kowalski@new-work.se>
Co-authored-by: Markus Wolf <markus.wolf@new-work.se> Co-authored-by: Philipp Hinrichsen <philipp.hinrichsen@new-work.se> Co-authored-by: Robert Kowalski <robert.kowalski@new-work.se>
ZauberNerd
force-pushed
the
fix-importcomponent
branch
from
February 2, 2022 14:48
23fd418
to
9df7b14
Compare
robertkowalski
force-pushed
the
fix-importcomponent
branch
from
February 15, 2022 11:02
6a1c776
to
4c71679
Compare
in the current setup, webpack builds where still running when the puppeteer tests would start, which leads to timeout issues, especially on slow machines like CI servers. This commit waits for the build to finish before continuing with `getUrl`, which is called by the integration tests upfront Co-authored-by: Björn Brauer <bjoern.brauer@new-work.se>
robertkowalski
force-pushed
the
fix-importcomponent
branch
from
February 15, 2022 11:11
4c71679
to
dbf793b
Compare
robertkowalski
previously approved these changes
Feb 15, 2022
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.
boom!
ZauberNerd
force-pushed
the
fix-importcomponent
branch
2 times, most recently
from
February 15, 2022 16:12
680bb5b
to
6886295
Compare
Co-authored-by: Robert Kowalski <robert.kowalski@new-work.se>
ZauberNerd
force-pushed
the
fix-importcomponent
branch
from
February 15, 2022 16:32
6886295
to
e33f6cf
Compare
We've got a flaky test:
|
Co-authored-by: Björn Brauer <bjoern.brauer@new-work.se>
robertkowalski
approved these changes
Feb 16, 2022
bors merge |
Build succeeded:
|
1 task
Cherry-pick failed on branch v15.x! Please check out PR #2078 & resolve the conflicts. |
Merged
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.
Ref: #1632, #1976
Todo:
namedChunkGroups
which point to the same asset.Bors merge bot cheat sheet
We are using bors-ng to automate merging of our pull requests. The following table provides a summary of commands that are available to reviewers (members of this repository with push access) and delegates (in case of
bors delegate+
orbors delegate=[list]
).This is a short collection of opinionated commands. For a full list of the commands read the bors reference.