Skip to content

Commit 6630f46

Browse files
authored
Merge pull request #362 from rohit-nair/rn/storybook-upgrade-v6
deps: Upgrade storybook to v6.x
2 parents 0db6be4 + e2a79ca commit 6630f46

File tree

3 files changed

+2609
-3079
lines changed

3 files changed

+2609
-3079
lines changed

app/.storybook/main.js

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ module.exports = {
22
stories: [
33
// display the Loop page as the first story int he list
44
'../src/__stories__/LoopPage.stories.tsx',
5-
'../src/**/*.stories.(ts|tsx|js|jsx|mdx)',
5+
'../src/**/*.stories.@(ts|tsx|js|jsx|mdx)',
66
],
77
addons: [
88
'@storybook/preset-create-react-app',
@@ -15,4 +15,12 @@ module.exports = {
1515
},
1616
},
1717
],
18+
core: {
19+
builder: 'webpack5'
20+
},
21+
features: {
22+
// Emotion11 quasi compatibility issue with storybook. Disabling feature flag to support emotion11.
23+
// https://github.com/storybookjs/storybook/blob/next/MIGRATION.md#emotion11-quasi-compatibility
24+
emotionAlias: false,
25+
},
1826
};

app/package.json

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -51,12 +51,14 @@
5151
"styled-components": "5.1.1"
5252
},
5353
"devDependencies": {
54-
"@storybook/addon-actions": "5.3.19",
55-
"@storybook/addon-docs": "5.3.19",
56-
"@storybook/addon-links": "5.3.19",
57-
"@storybook/addons": "5.3.19",
58-
"@storybook/preset-create-react-app": "3.1.2",
59-
"@storybook/react": "5.3.19",
54+
"@storybook/addon-actions": "6.5.5",
55+
"@storybook/addon-docs": "6.5.5",
56+
"@storybook/addon-links": "6.5.5",
57+
"@storybook/addons": "6.5.5",
58+
"@storybook/builder-webpack5": "6.5.5",
59+
"@storybook/manager-webpack5": "6.5.5",
60+
"@storybook/preset-create-react-app": "4.1.1",
61+
"@storybook/react": "6.5.5",
6062
"@testing-library/jest-dom": "5.11.5",
6163
"@testing-library/react": "11.1.1",
6264
"@testing-library/user-event": "12.2.0",
@@ -87,7 +89,8 @@
8789
"prettier": "2.1.2",
8890
"sass": "1.43.4",
8991
"ts-protoc-gen": "0.12.0",
90-
"typescript": "4.1.6"
92+
"typescript": "4.1.6",
93+
"webpack": "5"
9194
},
9295
"eslintConfig": {
9396
"extends": "react-app",

0 commit comments

Comments
 (0)