-
Notifications
You must be signed in to change notification settings - Fork 3.3k
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
⬆️ storybook@7 #2629
⬆️ storybook@7 #2629
Conversation
// fix to make absolute imports working in storybook | ||
webpackFinal: async (config, { configType }) => { | ||
config.resolve.alias = { | ||
...config.resolve.alias, | ||
src: path.resolve(__dirname, "../src"), | ||
styles: path.resolve(__dirname, "../styles"), | ||
}; |
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.
This is not needed anymore as storybook now works with next.js automatically.
@@ -114,8 +112,10 @@ | |||
"jest-environment-jsdom": "^29.5.0", | |||
"msw": "^0.49.3", | |||
"msw-storybook-addon": "^1.8.0", | |||
"path-browserify": "^1.0.1", |
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.
We already use this in website/.storybook/main.js
so it makes sense to explicitly add this to the dev dependencies.
"@testing-library/jest-dom": "^5.16.5", | ||
"@testing-library/react": "^13.4.0", | ||
"@types/accept-language-parser": "^1.5.3", | ||
"@types/node": "^18.15.10", | ||
"@types/react": "18.0.26", | ||
"@types/react-syntax-highlighter": "^15.5.6", | ||
"@typescript-eslint/eslint-plugin": "^5.56.0", | ||
"assert": "^2.0.0", |
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.
This is required since webpack 5 (the default in storybook v7) doesn't include a polyfill for assert by default anymore.
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.
Thank you so much! I'm tired to see those warning...
This PR updates storybook to version 7 following their migration guide to fix #1400.