-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Add UMD builds backs in the core #3390
Conversation
🦋 Changeset detectedLatest commit: 8da759c The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
This pull request is automatically built and testable in CodeSandbox. To see build info of the built libraries, click here or the icon next to each commit SHA. Latest deployment of this branch, based on commit 8da759c:
|
👇 Click on the image for a new way to code review
Legend |
f307a5d
to
8da759c
Compare
@@ -1,4 +0,0 @@ | |||
{ |
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.
We've missed this in #3187
I'm leaning toward reverting this. UMDs are a weird beast of the past. In today's landscape, you can either use a bundler-powered CDN like Skypack or you can find the ESM files in our packages that are compatible with browsers. |
I'm not a fan of shipping those in 2022 but this has been asked on Discord. I don't want to work too much on those bundles because I think that if somebody needs those then they need to figure out creating those on their end (it's not that hard and we won't have a lot of consumers for those bundles nowadays).
The main problem with them for us is that Rollup doesn't support code-splitting for such targets:
This can easily be checked on their playground
So since code-splitting isnt' supported we have to bundle all of the entrypoints separately and that might cause issues with shared state,
instanceof
and similar.Alternatively we could prepare special "all at once" UMD bundles but... that would complicate our setup and would have rather poor RoI given how niche those bundles are nowadays.
I'm kinda providing those here with a disclaimer that YMMV. I didn't test them in full and stuff might not work properly.