-
Notifications
You must be signed in to change notification settings - Fork 7
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
Provide Rspack Storybook builder? #92
Comments
This would be really great. For example, if you're migrating a project from webpack to rspack, you don't need rsbuild. But then you want to migrate storybook as well, and you suddenly need rsbuild, which comes with its own dependencies, config file and plugins. I don't think specific rspack frameworks are the way to go, but if storybook-rsbuild could support reading a rspack.config instead of an rsbuild.config, that would be great. e: I realized that the rspack config of an app will always be somewhat incompatible with storybook. But rsbuild does make it easy to re-use the config you need. Here's for example my minimal vue3 + storybook + rsbuild via rspack config:
Maybe something like this could be added to the docs. |
This is a way to use Rspack config with storybook-builder-rsbuild, but it's not verified in many scenes. Rsbuild has many built-in features, so that may cause an implicit difference. Providing Rspack builder is not hard IMO, we're considering to support in the future. |
You are right, my example doesn't actually work when building, only when watching. In build mode, experiments: css extracts the css into chunks, but storybook / rsbuild expects the original chunks for each vue component. Or something like that. |
This would be awesome to have. We're trying to migrate a pretty big and old project from webpack to rspack. It all works and the performance is so much better (e.g. hmr time was reduced from ~8s to ~0.5s), but Storybook is unfortunately a blocker for us. Maybe we could keep using webpack just for Storybook for now and use rspack for the app. |
I'll take a time to check out how to extract the webpack / Rspack configurations from webpack.config.js / rspack.config.js. TBH, as per #88 (comment). It's possible to achieve of reuse of webpack config, the remaining questions are:
|
Please use the reaction with 👍 to vote for support Rspack bulider with Storybook.
The text was updated successfully, but these errors were encountered: