-
Notifications
You must be signed in to change notification settings - Fork 27.1k
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
WIP Feature/storybook default import #18367
Conversation
Stats from current PRDefault Server Mode (Decrease detected ✓)General
Page Load Tests Overall decrease
|
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
/ failed reqs | 0 | 0 | ✓ |
/ total time (seconds) | 2.813 | 2.776 | -0.04 |
/ avg req/sec | 888.61 | 900.54 | +11.93 |
/error-in-render failed reqs | 0 | 0 | ✓ |
/error-in-render total time (seconds) | 1.762 | 1.847 | |
/error-in-render avg req/sec | 1418.79 | 1353.25 |
Client Bundles (main, webpack, commons)
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
677f882d2ed8..3aa9.js gzip | 11.3 kB | 11.3 kB | ✓ |
framework.HASH.js gzip | 39 kB | 39 kB | ✓ |
main-fc2ed98..cd2b.js gzip | 7.33 kB | 7.33 kB | ✓ |
webpack-e067..f178.js gzip | 751 B | 751 B | ✓ |
Overall change | 58.3 kB | 58.3 kB | ✓ |
Client Bundles (main, webpack, commons) Modern
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
677f882d2ed8..dule.js gzip | 7.03 kB | 7.03 kB | ✓ |
framework.HA..dule.js gzip | 39 kB | 39 kB | ✓ |
main-20f9619..dule.js gzip | 6.31 kB | 6.31 kB | ✓ |
webpack-07c5..dule.js gzip | 751 B | 751 B | ✓ |
Overall change | 53.1 kB | 53.1 kB | ✓ |
Legacy Client Bundles (polyfills)
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
polyfills-4b..e242.js gzip | 31 kB | 31 kB | ✓ |
Overall change | 31 kB | 31 kB | ✓ |
Client Pages
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
_app-9a0b9e1..b37e.js gzip | 1.28 kB | 1.28 kB | ✓ |
_error-ed1b0..8fbd.js gzip | 3.44 kB | 3.44 kB | ✓ |
hooks-89731c..c609.js gzip | 887 B | 887 B | ✓ |
index-17468f..5d83.js gzip | 227 B | 227 B | ✓ |
link-41ceea0..6b62.js gzip | 1.35 kB | 1.35 kB | ✓ |
routerDirect..924c.js gzip | 284 B | 284 B | ✓ |
withRouter-7..c13d.js gzip | 284 B | 284 B | ✓ |
Overall change | 7.75 kB | 7.75 kB | ✓ |
Client Pages Modern
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
_app-75d3a82..dule.js gzip | 625 B | 625 B | ✓ |
_error-4469a..dule.js gzip | 2.29 kB | 2.29 kB | ✓ |
hooks-cbf13f..dule.js gzip | 387 B | 387 B | ✓ |
index-b9a643..dule.js gzip | 226 B | 226 B | ✓ |
link-2d41a89..dule.js gzip | 1.31 kB | 1.31 kB | ✓ |
routerDirect..dule.js gzip | 284 B | 284 B | ✓ |
withRouter-f..dule.js gzip | 282 B | 282 B | ✓ |
Overall change | 5.4 kB | 5.4 kB | ✓ |
Client Build Manifests
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
_buildManifest.js gzip | 323 B | 323 B | ✓ |
_buildManife..dule.js gzip | 329 B | 329 B | ✓ |
Overall change | 652 B | 652 B | ✓ |
Rendered Page Sizes
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
index.html gzip | 1 kB | 1 kB | ✓ |
link.html gzip | 1.01 kB | 1.01 kB | ✓ |
withRouter.html gzip | 996 B | 996 B | ✓ |
Overall change | 3.01 kB | 3.01 kB | ✓ |
Serverless Mode
General
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
buildDuration | 16.6s | 16.5s | -148ms |
nodeModulesSize | 91.3 MB | 91.3 MB | ✓ |
Client Bundles (main, webpack, commons)
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
677f882d2ed8..3aa9.js gzip | 11.3 kB | 11.3 kB | ✓ |
framework.HASH.js gzip | 39 kB | 39 kB | ✓ |
main-fc2ed98..cd2b.js gzip | 7.33 kB | 7.33 kB | ✓ |
webpack-e067..f178.js gzip | 751 B | 751 B | ✓ |
Overall change | 58.3 kB | 58.3 kB | ✓ |
Client Bundles (main, webpack, commons) Modern
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
677f882d2ed8..dule.js gzip | 7.03 kB | 7.03 kB | ✓ |
framework.HA..dule.js gzip | 39 kB | 39 kB | ✓ |
main-20f9619..dule.js gzip | 6.31 kB | 6.31 kB | ✓ |
webpack-07c5..dule.js gzip | 751 B | 751 B | ✓ |
Overall change | 53.1 kB | 53.1 kB | ✓ |
Legacy Client Bundles (polyfills)
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
polyfills-4b..e242.js gzip | 31 kB | 31 kB | ✓ |
Overall change | 31 kB | 31 kB | ✓ |
Client Pages
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
_app-9a0b9e1..b37e.js gzip | 1.28 kB | 1.28 kB | ✓ |
_error-ed1b0..8fbd.js gzip | 3.44 kB | 3.44 kB | ✓ |
hooks-89731c..c609.js gzip | 887 B | 887 B | ✓ |
index-17468f..5d83.js gzip | 227 B | 227 B | ✓ |
link-41ceea0..6b62.js gzip | 1.35 kB | 1.35 kB | ✓ |
routerDirect..924c.js gzip | 284 B | 284 B | ✓ |
withRouter-7..c13d.js gzip | 284 B | 284 B | ✓ |
Overall change | 7.75 kB | 7.75 kB | ✓ |
Client Pages Modern
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
_app-75d3a82..dule.js gzip | 625 B | 625 B | ✓ |
_error-4469a..dule.js gzip | 2.29 kB | 2.29 kB | ✓ |
hooks-cbf13f..dule.js gzip | 387 B | 387 B | ✓ |
index-b9a643..dule.js gzip | 226 B | 226 B | ✓ |
link-2d41a89..dule.js gzip | 1.31 kB | 1.31 kB | ✓ |
routerDirect..dule.js gzip | 284 B | 284 B | ✓ |
withRouter-f..dule.js gzip | 282 B | 282 B | ✓ |
Overall change | 5.4 kB | 5.4 kB | ✓ |
Client Build Manifests
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
_buildManifest.js gzip | 323 B | 323 B | ✓ |
_buildManife..dule.js gzip | 329 B | 329 B | ✓ |
Overall change | 652 B | 652 B | ✓ |
Serverless bundles
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
_error.js | 1.06 MB | 1.06 MB | ✓ |
404.html | 4.73 kB | 4.73 kB | ✓ |
hooks.html | 3.92 kB | 3.92 kB | ✓ |
index.js | 1.06 MB | 1.06 MB | ✓ |
link.js | 1.11 MB | 1.11 MB | ✓ |
routerDirect.js | 1.1 MB | 1.1 MB | ✓ |
withRouter.js | 1.1 MB | 1.1 MB | ✓ |
Overall change | 5.43 MB | 5.43 MB | ✓ |
Currently it's advised not to use |
@weyert Latest version should work fine (10.0.1), so you can use it. Also we need to wait for the next version of Storybook to stabilize Storybook and Next integration. Currently you may have React version mismatches, but fixing it is Storybook team priority right now so it will be fixed very soon. I'll finish the PR on Storybook docs and send a PR an update to the README when everything is stable and tested. |
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.
@eric-burel Please let me know when the PR is ready for review 🙏
@lfades I've just updated on latest canary and fixed the conflicts. What blocks me is that The code is otherwise fine, it is the same as before except I've changed Edit: the build produces a JS file, but then if I try to use the package in |
Stats from current PRDefault Server Mode (Decrease detected ✓)General
Page Load Tests Overall decrease
|
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
/ failed reqs | 0 | 0 | ✓ |
/ total time (seconds) | 2.537 | 2.447 | -0.09 |
/ avg req/sec | 985.4 | 1021.48 | +36.08 |
/error-in-render failed reqs | 0 | 0 | ✓ |
/error-in-render total time (seconds) | 1.329 | 1.414 | |
/error-in-render avg req/sec | 1880.86 | 1767.9 |
Client Bundles (main, webpack, commons)
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
677f882d2ed8..776c.js gzip | 12.7 kB | 12.7 kB | ✓ |
framework.HASH.js gzip | 39 kB | 39 kB | ✓ |
main-95c0df2..6c91.js gzip | 6.53 kB | 6.53 kB | ✓ |
webpack-e067..f178.js gzip | 751 B | 751 B | ✓ |
Overall change | 58.9 kB | 58.9 kB | ✓ |
Client Bundles (main, webpack, commons) Modern
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
677f882d2ed8..dule.js gzip | 8.26 kB | 8.26 kB | ✓ |
framework.HA..dule.js gzip | 39 kB | 39 kB | ✓ |
main-8ead8dd..dule.js gzip | 5.64 kB | 5.64 kB | ✓ |
webpack-07c5..dule.js gzip | 751 B | 751 B | ✓ |
Overall change | 53.6 kB | 53.6 kB | ✓ |
Legacy Client Bundles (polyfills)
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
polyfills-4b..e242.js gzip | 31 kB | 31 kB | ✓ |
Overall change | 31 kB | 31 kB | ✓ |
Client Pages
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
_app-3b0cf13..85f8.js gzip | 1.28 kB | 1.28 kB | ✓ |
_error-6f635..c393.js gzip | 3.44 kB | 3.44 kB | ✓ |
hooks-d4ffc3..9e0f.js gzip | 887 B | 887 B | ✓ |
index-17468f..5d83.js gzip | 227 B | 227 B | ✓ |
link-d9a15a0..130a.js gzip | 1.57 kB | 1.57 kB | ✓ |
routerDirect..924c.js gzip | 284 B | 284 B | ✓ |
withRouter-7..c13d.js gzip | 284 B | 284 B | ✓ |
Overall change | 7.98 kB | 7.98 kB | ✓ |
Client Pages Modern
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
_app-75d3a82..dule.js gzip | 625 B | 625 B | ✓ |
_error-f2fcc..dule.js gzip | 2.29 kB | 2.29 kB | ✓ |
hooks-cbf13f..dule.js gzip | 387 B | 387 B | ✓ |
index-b9a643..dule.js gzip | 226 B | 226 B | ✓ |
link-973cce3..dule.js gzip | 1.51 kB | 1.51 kB | ✓ |
routerDirect..dule.js gzip | 284 B | 284 B | ✓ |
withRouter-f..dule.js gzip | 282 B | 282 B | ✓ |
Overall change | 5.6 kB | 5.6 kB | ✓ |
Client Build Manifests
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
_buildManifest.js gzip | 321 B | 321 B | ✓ |
_buildManife..dule.js gzip | 330 B | 330 B | ✓ |
Overall change | 651 B | 651 B | ✓ |
Rendered Page Sizes
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
index.html gzip | 968 B | 968 B | ✓ |
link.html gzip | 974 B | 974 B | ✓ |
withRouter.html gzip | 961 B | 961 B | ✓ |
Overall change | 2.9 kB | 2.9 kB | ✓ |
Serverless Mode
General
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
buildDuration | 15.7s | 15.3s | -454ms |
nodeModulesSize | 85 MB | 85 MB | ✓ |
Client Bundles (main, webpack, commons)
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
677f882d2ed8..776c.js gzip | 12.7 kB | 12.7 kB | ✓ |
framework.HASH.js gzip | 39 kB | 39 kB | ✓ |
main-95c0df2..6c91.js gzip | 6.53 kB | 6.53 kB | ✓ |
webpack-e067..f178.js gzip | 751 B | 751 B | ✓ |
Overall change | 58.9 kB | 58.9 kB | ✓ |
Client Bundles (main, webpack, commons) Modern
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
677f882d2ed8..dule.js gzip | 8.26 kB | 8.26 kB | ✓ |
framework.HA..dule.js gzip | 39 kB | 39 kB | ✓ |
main-8ead8dd..dule.js gzip | 5.64 kB | 5.64 kB | ✓ |
webpack-07c5..dule.js gzip | 751 B | 751 B | ✓ |
Overall change | 53.6 kB | 53.6 kB | ✓ |
Legacy Client Bundles (polyfills)
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
polyfills-4b..e242.js gzip | 31 kB | 31 kB | ✓ |
Overall change | 31 kB | 31 kB | ✓ |
Client Pages
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
_app-3b0cf13..85f8.js gzip | 1.28 kB | 1.28 kB | ✓ |
_error-6f635..c393.js gzip | 3.44 kB | 3.44 kB | ✓ |
hooks-d4ffc3..9e0f.js gzip | 887 B | 887 B | ✓ |
index-17468f..5d83.js gzip | 227 B | 227 B | ✓ |
link-d9a15a0..130a.js gzip | 1.57 kB | 1.57 kB | ✓ |
routerDirect..924c.js gzip | 284 B | 284 B | ✓ |
withRouter-7..c13d.js gzip | 284 B | 284 B | ✓ |
Overall change | 7.98 kB | 7.98 kB | ✓ |
Client Pages Modern
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
_app-75d3a82..dule.js gzip | 625 B | 625 B | ✓ |
_error-f2fcc..dule.js gzip | 2.29 kB | 2.29 kB | ✓ |
hooks-cbf13f..dule.js gzip | 387 B | 387 B | ✓ |
index-b9a643..dule.js gzip | 226 B | 226 B | ✓ |
link-973cce3..dule.js gzip | 1.51 kB | 1.51 kB | ✓ |
routerDirect..dule.js gzip | 284 B | 284 B | ✓ |
withRouter-f..dule.js gzip | 282 B | 282 B | ✓ |
Overall change | 5.6 kB | 5.6 kB | ✓ |
Client Build Manifests
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
_buildManifest.js gzip | 321 B | 321 B | ✓ |
_buildManife..dule.js gzip | 330 B | 330 B | ✓ |
Overall change | 651 B | 651 B | ✓ |
Serverless bundles
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
_error.js | 918 kB | 918 kB | ✓ |
404.html | 4.61 kB | 4.61 kB | ✓ |
hooks.html | 3.86 kB | 3.86 kB | ✓ |
index.js | 918 kB | 918 kB | ✓ |
link.js | 976 kB | 976 kB | ✓ |
routerDirect.js | 969 kB | 969 kB | ✓ |
withRouter.js | 969 kB | 969 kB | ✓ |
Overall change | 4.76 MB | 4.76 MB | ✓ |
Stats from current PRDefault Server Mode (Decrease detected ✓)General
Page Load Tests Overall decrease
|
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
/ failed reqs | 0 | 0 | ✓ |
/ total time (seconds) | 2.114 | 2.126 | |
/ avg req/sec | 1182.43 | 1176.17 | |
/error-in-render failed reqs | 0 | 0 | ✓ |
/error-in-render total time (seconds) | 1.11 | 1.149 | |
/error-in-render avg req/sec | 2251.85 | 2176.25 |
Client Bundles (main, webpack, commons)
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
677f882d2ed8..5e70.js gzip | 12.8 kB | 12.8 kB | ✓ |
framework.HASH.js gzip | 39 kB | 39 kB | ✓ |
main-1f21dcf..0011.js gzip | 6.56 kB | 6.56 kB | ✓ |
webpack-95c2..e870.js gzip | 751 B | 751 B | ✓ |
Overall change | 59 kB | 59 kB | ✓ |
Legacy Client Bundles (polyfills)
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
polyfills-d3..23f6.js gzip | 31 kB | 31 kB | ✓ |
Overall change | 31 kB | 31 kB | ✓ |
Client Pages
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
_app-0d19cb6..5497.js gzip | 1.28 kB | 1.28 kB | ✓ |
_error-2cf0e..a0a0.js gzip | 3.69 kB | 3.69 kB | ✓ |
hooks-42456f..0c06.js gzip | 887 B | 887 B | ✓ |
index-8081ce..e44f.js gzip | 227 B | 227 B | ✓ |
link-0ab9f83..fa00.js gzip | 1.61 kB | 1.61 kB | ✓ |
routerDirect..c3d8.js gzip | 303 B | 303 B | ✓ |
withRouter-0..a68e.js gzip | 302 B | 302 B | ✓ |
Overall change | 8.31 kB | 8.31 kB | ✓ |
Client Build Manifests
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
_buildManifest.js gzip | 323 B | 323 B | ✓ |
Overall change | 323 B | 323 B | ✓ |
Rendered Page Sizes
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
index.html gzip | 612 B | 612 B | ✓ |
link.html gzip | 619 B | 619 B | ✓ |
withRouter.html gzip | 608 B | 608 B | ✓ |
Overall change | 1.84 kB | 1.84 kB | ✓ |
Serverless Mode
General
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
buildDuration | 10.4s | 10.9s | |
nodeModulesSize | 82.4 MB | 82.4 MB | ✓ |
Client Bundles (main, webpack, commons)
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
677f882d2ed8..5e70.js gzip | 12.8 kB | 12.8 kB | ✓ |
framework.HASH.js gzip | 39 kB | 39 kB | ✓ |
main-1f21dcf..0011.js gzip | 6.56 kB | 6.56 kB | ✓ |
webpack-95c2..e870.js gzip | 751 B | 751 B | ✓ |
Overall change | 59 kB | 59 kB | ✓ |
Legacy Client Bundles (polyfills)
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
polyfills-d3..23f6.js gzip | 31 kB | 31 kB | ✓ |
Overall change | 31 kB | 31 kB | ✓ |
Client Pages
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
_app-0d19cb6..5497.js gzip | 1.28 kB | 1.28 kB | ✓ |
_error-2cf0e..a0a0.js gzip | 3.69 kB | 3.69 kB | ✓ |
hooks-42456f..0c06.js gzip | 887 B | 887 B | ✓ |
index-8081ce..e44f.js gzip | 227 B | 227 B | ✓ |
link-0ab9f83..fa00.js gzip | 1.61 kB | 1.61 kB | ✓ |
routerDirect..c3d8.js gzip | 303 B | 303 B | ✓ |
withRouter-0..a68e.js gzip | 302 B | 302 B | ✓ |
Overall change | 8.31 kB | 8.31 kB | ✓ |
Client Build Manifests
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
_buildManifest.js gzip | 323 B | 323 B | ✓ |
Overall change | 323 B | 323 B | ✓ |
Serverless bundles
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
_error.js | 1 MB | 1 MB | ✓ |
404.html | 2.67 kB | 2.67 kB | ✓ |
hooks.html | 1.92 kB | 1.92 kB | ✓ |
index.js | 1 MB | 1 MB | ✓ |
link.js | 1.06 MB | 1.06 MB | ✓ |
routerDirect.js | 1.05 MB | 1.05 MB | ✓ |
withRouter.js | 1.05 MB | 1.05 MB | ✓ |
Overall change | 5.16 MB | 5.16 MB | ✓ |
Failing test suitesCommit: 641e3be test/integration/production-build-dir/test/index.test.js
Expand output● Production Custom Build Directory › With basic usage › should render the page
|
…TS file instead of plugin
Stats from current PRDefault Server Mode (Increase detected
|
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
buildDuration | 9.9s | 9.9s | -26ms |
nodeModulesSize | 82.4 MB | 82.4 MB | ✓ |
Page Load Tests Overall increase ✓
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
/ failed reqs | 0 | 0 | ✓ |
/ total time (seconds) | 2.362 | 2.359 | 0 |
/ avg req/sec | 1058.41 | 1059.78 | +1.37 |
/error-in-render failed reqs | 0 | 0 | ✓ |
/error-in-render total time (seconds) | 1.272 | 1.196 | -0.08 |
/error-in-render avg req/sec | 1964.93 | 2090.41 | +125.48 |
Client Bundles (main, webpack, commons)
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
677f882d2ed8..5e70.js gzip | 12.8 kB | 12.8 kB | ✓ |
framework.HASH.js gzip | 39 kB | 39 kB | ✓ |
main-1f21dcf..0011.js gzip | 6.56 kB | 6.56 kB | ✓ |
webpack-95c2..e870.js gzip | 751 B | 751 B | ✓ |
Overall change | 59 kB | 59 kB | ✓ |
Legacy Client Bundles (polyfills)
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
polyfills-d3..23f6.js gzip | 31 kB | 31 kB | ✓ |
Overall change | 31 kB | 31 kB | ✓ |
Client Pages
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
_app-0d19cb6..5497.js gzip | 1.28 kB | 1.28 kB | ✓ |
_error-2cf0e..a0a0.js gzip | 3.69 kB | 3.69 kB | ✓ |
hooks-42456f..0c06.js gzip | 887 B | 887 B | ✓ |
index-8081ce..e44f.js gzip | 227 B | 227 B | ✓ |
link-0ab9f83..fa00.js gzip | 1.61 kB | 1.61 kB | ✓ |
routerDirect..c3d8.js gzip | 303 B | 303 B | ✓ |
withRouter-0..a68e.js gzip | 302 B | 302 B | ✓ |
Overall change | 8.31 kB | 8.31 kB | ✓ |
Client Build Manifests
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
_buildManifest.js gzip | 323 B | 323 B | ✓ |
Overall change | 323 B | 323 B | ✓ |
Rendered Page Sizes
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
index.html gzip | 612 B | 612 B | ✓ |
link.html gzip | 619 B | 619 B | ✓ |
withRouter.html gzip | 608 B | 608 B | ✓ |
Overall change | 1.84 kB | 1.84 kB | ✓ |
Serverless Mode
General
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
buildDuration | 11.7s | 11.6s | -127ms |
nodeModulesSize | 82.4 MB | 82.4 MB | ✓ |
Client Bundles (main, webpack, commons)
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
677f882d2ed8..5e70.js gzip | 12.8 kB | 12.8 kB | ✓ |
framework.HASH.js gzip | 39 kB | 39 kB | ✓ |
main-1f21dcf..0011.js gzip | 6.56 kB | 6.56 kB | ✓ |
webpack-95c2..e870.js gzip | 751 B | 751 B | ✓ |
Overall change | 59 kB | 59 kB | ✓ |
Legacy Client Bundles (polyfills)
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
polyfills-d3..23f6.js gzip | 31 kB | 31 kB | ✓ |
Overall change | 31 kB | 31 kB | ✓ |
Client Pages
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
_app-0d19cb6..5497.js gzip | 1.28 kB | 1.28 kB | ✓ |
_error-2cf0e..a0a0.js gzip | 3.69 kB | 3.69 kB | ✓ |
hooks-42456f..0c06.js gzip | 887 B | 887 B | ✓ |
index-8081ce..e44f.js gzip | 227 B | 227 B | ✓ |
link-0ab9f83..fa00.js gzip | 1.61 kB | 1.61 kB | ✓ |
routerDirect..c3d8.js gzip | 303 B | 303 B | ✓ |
withRouter-0..a68e.js gzip | 302 B | 302 B | ✓ |
Overall change | 8.31 kB | 8.31 kB | ✓ |
Client Build Manifests
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
_buildManifest.js gzip | 323 B | 323 B | ✓ |
Overall change | 323 B | 323 B | ✓ |
Serverless bundles
vercel/next.js canary | lbke/next.js feature/storybook-default-import | Change | |
---|---|---|---|
_error.js | 1 MB | 1 MB | ✓ |
404.html | 2.67 kB | 2.67 kB | ✓ |
hooks.html | 1.92 kB | 1.92 kB | ✓ |
index.js | 1 MB | 1 MB | ✓ |
link.js | 1.06 MB | 1.06 MB | ✓ |
routerDirect.js | 1.05 MB | 1.05 MB | ✓ |
withRouter.js | 1.05 MB | 1.05 MB | ✓ |
Overall change | 5.16 MB | 5.16 MB | ✓ |
next.js/packages/next-plugin-storybook/preset.js Lines 28 to 40 in cef4b4b
Should be: config.module.rules = [
// ...
]; Causes:
|
I think the change referenced by @chasewalden is from @ja0n 's PR I think I might leave the "preset" file as is if I can't figure a solution and only keep the |
Closed in favour of #23020 |
This fixes a bug in `@next/plugin-storybook` caused by an update in the rewrite structure, solution was provided by @stefanprobst #19345 (comment) Secondary question: it would be awesome if someone at Next could help translating `preset.js` into TypeScript, this would catch those bugs immediately. I've tried in #18367 but failed to build correctly. ## Bug - [X] Related issues linked using `fixes #number` => parent issue is an umbrella of various small issues: #19345 - [X] Integration tests added => reproduction is implemented in https://github.com/lbke/next-plugin-storybook-demo until the package is more stable
This fixes a bug in `@next/plugin-storybook` caused by an update in the rewrite structure, solution was provided by @stefanprobst vercel#19345 (comment) Secondary question: it would be awesome if someone at Next could help translating `preset.js` into TypeScript, this would catch those bugs immediately. I've tried in vercel#18367 but failed to build correctly. ## Bug - [X] Related issues linked using `fixes #number` => parent issue is an umbrella of various small issues: vercel#19345 - [X] Integration tests added => reproduction is implemented in https://github.com/lbke/next-plugin-storybook-demo until the package is more stable
with-storybook
example with an example of module path alias as described in https://nextjs.org/docs/advanced-features/module-path-aliases.This completes PR #18364 that provides a quickfix in JavaScript already.
Since the issue would have been caught immediately in TS, switching the package to TS is probably the best solution.
However I did not manage to make it build reliably, nor to import it in the
with-storybook
example (I get thisCannot find module 'next/lib/find-pages-dir'
).Current issues:
import type
, they don't work.yarn why typescript
also gives:=> Found "microbundle#[email protected]"
(in addition to the normal TS install on version 3.8.3). So the local binarytsc
is at version3.7.5
, which is not compatible withimport type
. I don't know how Next itself is built and how it uses the correct version of TypeScript.getWebpackConfig
is clearly overkill. It should be split into pieces, eg addingpaths
from thejsconfig
ortsconfig
, adding plugins, and so on, and we should add those helpers one after the other in Storybook. Loading all at once is room for trouble and raise issues in end applications (@next/plugin-storybook issues #19345)Next steps:
paths
fromjsconfig
/tsconfig
to generate the webpack alias so thewith-storybook
example works ok