-
-
Notifications
You must be signed in to change notification settings - Fork 9.4k
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
[Bug]: Investigate code getting pre-bundled multiple times #20514
Comments
These are all the commonJS files, which do indeed not tree-shake, and for backwards compatibility have all the old code still present/bundled. What are we measuring here? |
I can't say with full confidence, but I think these commonjs files would only ever be used by storyshots, I think. |
I verified that the MJS files are in the prebundle. |
I have noticed that the deprecation warnings for the removed packages don't actually make it into the ESM dist (they do appear in the CJS dist) |
I verified, that in the webpack-builder the externalisation of the packages we want work correctly, and they are all ESM. |
I found that vite-builder was using :
But this resulted in the code existing multiple times.
made it work! |
will open a PR. |
w00t!! I just released https://github.com/storybookjs/storybook/releases/tag/v7.0.0-beta.26 containing PR #20594 that references this issue. Upgrade today to the
Closing this issue. Please re-open if you think there's still more to do. |
Describe the bug
Inside the new
preview-api
package things appear to be included too many times. For example:Note that this is also bundled in the
preview
package as well, further contributing to the install size.This may contribute to a ballooning install size in our benchmarks:
To Reproduce
No response
System
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: