-
-
Notifications
You must be signed in to change notification settings - Fork 9.5k
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
Update webpack extend warning. #2660
Conversation
Flesh out the repercussions of replacing module rules.
Codecov Report
@@ Coverage Diff @@
## master #2660 +/- ##
=======================================
Coverage 34.34% 34.34%
=======================================
Files 389 389
Lines 8750 8750
Branches 927 904 -23
=======================================
Hits 3005 3005
- Misses 5107 5140 +33
+ Partials 638 605 -33
Continue to review full report at Codecov.
|
@@ -38,7 +38,7 @@ Since this config file stays in the Storybook directory, you need to set the inc | |||
|
|||
You also need to install the loaders (style, css, and sass) used in above config manually. | |||
|
|||
> Once you create this `webpack.config.js` file, Storybook won't load the [default Webpack config](/configurations/default-config/) other than loading JS files with the Babel loader. | |||
> Once you create this `webpack.config.js` file, Storybook won't load the [default Webpack config](/configurations/default-config/) other than loading JS files with the Babel loader. This will disable included functionality like svg loading. Read on to learn how to [retain defaults](#full-control-mode--default). |
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.
Extend mode retains defaults as well
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.
I don't think I discovered a regression and the existing documentation contradicts that. This is the existing documentation: Once you create this webpack.config.js
file, Storybook won't load the default Webpack config other than loading JS files with the Babel loader. I've only extended it to highlight the kind of functionality that's lost when this happens and link to the better solution down the page.
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.
I meant that there's a sense in linking to #extend-mode
instead, but now I see that this is already in this section. It's quite weird actually, need to investigate why is it so.
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.
Oh, nevermind. I actually was wrong and extend mode extends baseConfig
, not the default one
Update webpack extend warning.
Documentation update:
Flesh out the repercussions of replacing module rules.