Skip to content
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]: @storybook/nextjs incompatible with Next 13.4.3 #22686

Closed
yannbf opened this issue May 22, 2023 · 2 comments · Fixed by #22697
Closed

[Bug]: @storybook/nextjs incompatible with Next 13.4.3 #22686

yannbf opened this issue May 22, 2023 · 2 comments · Fixed by #22697

Comments

@yannbf
Copy link
Member

yannbf commented May 22, 2023

Describe the bug

When upgrading Next to 13.4.3 or higher, Storybook breaks with the following error:

WARN Force closed preview build
ModuleNotFoundError: Module not found: Error: Can't resolve 'fs' in '/Users/yannbraga/open-source/storybook/sandbox/nextjs-default-js/node_modules/next/dist/compiled/gzip-size'
    at /Users/yannbraga/open-source/storybook/sandbox/nextjs-default-js/node_modules/webpack/lib/Compilation.js:1512:33
    at /Users/yannbraga/open-source/storybook/sandbox/nextjs-default-js/node_modules/webpack/lib/NormalModuleFactory.js:656:18
    at eval (eval at create (/Users/yannbraga/open-source/storybook/sandbox/nextjs-default-js/node_modules/tapable/lib/HookCodeFactory.js:28:14), <anonymous>:10:1)

To Reproduce

Run yarn storybook in this sandbox

System

No response

Additional context

No response

@yannbf yannbf changed the title [Bug]: @storybook/nextjs incompatible with Next 13.4.3 and higher [Bug]: @storybook/nextjs incompatible with Next 13.4.3 May 23, 2023
@shilman
Copy link
Member

shilman commented May 23, 2023

Ermahgerd!! I just released https://github.com/storybookjs/storybook/releases/tag/v7.1.0-alpha.21 containing PR #22697 that references this issue. Upgrade today to the @future NPM tag to try it out!

npx sb@next upgrade --tag future

@shilman
Copy link
Member

shilman commented May 23, 2023

Ermahgerd!! I just released https://github.com/storybookjs/storybook/releases/tag/v7.0.15 containing PR #22697 that references this issue. Upgrade today to the @latest NPM tag to try it out!

npx sb@latest upgrade

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants