Closed omar-shahid closed 1 year ago
Looks like the problem is with npm, when I recreated the gatsby site and initialize the storybook with yarn, it works absolutely fine.
I am trying to integrate the storybook with the Gatsby JS project. But every time I start storybook using npm run storybook, it gives me this error.
I see this error too.
Looks like the problem is with npm, when I recreated the gatsby site and initialize the storybook with yarn, it works absolutely fine.
I do not see this--running with yarn results in the same error.
To me it helped to follow https://gist.github.com/shilman/8856ea1786dcd247139b47b270912324#upgrading-from-webpack-4.
Re-post:
Upgrading from Webpack 4
If you're upgrading an existing Storybook installation:
npx sb@next upgrade --prerelease
Then add dependencies:
npm i -D @storybook/builder-webpack5@next @storybook/manager-webpack5@next
Then update your .storybook/main.js:
module.exports = { core: { builder: "webpack5", }, };
Upgrading from 6.2 Webpack 5
If you were using Webpack 5 in 6.2, and have upgraded to 6.3, you probably need to add @storybook/manager-webpack5 as a dependency:
npm i -D @storybook/manager-webpack5@next
To me it helped to follow https://gist.github.com/shilman/8856ea1786dcd247139b47b270912324#upgrading-from-webpack-4.
Re-post:
Upgrading from Webpack 4 If you're upgrading an existing Storybook installation: npx sb@next upgrade --prerelease Then add dependencies: npm i -D @storybook/builder-webpack5@next @storybook/manager-webpack5@next Then update your .storybook/main.js: module.exports = { core: { builder: "webpack5", }, }; Upgrading from 6.2 Webpack 5 If you were using Webpack 5 in 6.2, and have upgraded to 6.3, you probably need to add @storybook/manager-webpack5 as a dependency: npm i -D @storybook/manager-webpack5@next
it's not work for me...
We’re cleaning house! Storybook has changed a lot since this issue was created and we don’t know if it’s still valid. Please open a new issue referencing this one if:
I am trying to integrate the storybook with the Gatsby JS project. But every time I start storybook using
npm run storybook
, it gives me this error. I tried using Storybook v5 after v6, but the error is still there. tried using web pack-5, but still got no avail. Please let me know how to fix this issue.