Why does @storybook/addon-docs have babel-loader as a peer dependency?
See original GitHub issueDescribe the bug When I install packages, I get this warning:
warning "@storybook/addon-docs@6.1.1" has unmet peer dependency "babel-loader@^8.0.0".
Why should I add babel-loader as a dependency when it already comes with Storybook? Doing so is kind of dangerous because it runs the risk of having mismatched versions in the dependency tree. It seems like this peer dependency is not needed.
To Reproduce Steps to reproduce the behavior:
- Install @storybook/addon-docs with yarn.
Expected behavior No warnings.
System
Environment Info:
System:
OS: Windows 10 10.0.19042
CPU: (4) x64 Intel(R) Core(TM) i7-6600U CPU @ 2.60GHz
Binaries:
Node: 14.15.0 - C:\Program Files\Node.js\node.EXE
Yarn: 1.22.5 - C:\Program Files (x86)\Yarn\bin\yarn.CMD
npm: 6.14.8 - C:\Program Files\Node.js\npm.CMD
Browsers:
Chrome: 86.0.4240.198
Edge: Spartan (44.19041.423.0), Chromium (86.0.622.69)
Issue Analytics
- State:
- Created 3 years ago
- Reactions:6
- Comments:33 (13 by maintainers)
Top Results From Across the Web
Problem with npm install - Could not resolve dependency. Is ...
I tried to launch --legacy-peer-deps but this creates a package-lock.json with "lockfileVersion" setted to 2. I want to create a regular ...
Read more >@storybook/addon-docs versions and peer dependencies
Online Peer dependency version tool to search for compatible versions of related NPM packages.
Read more >@storybook/addon-docs - npm
yarn add -D @storybook/addon-docs. Docs has peer dependencies on react . If you want to write stories in MDX, you may need to...
Read more >styled-components@5.3.5" has unmet peer dependency ...
0". warning " > @material-ui/core@4.12.4" has incorrect peer dependency "react-dom@^16.8.0 || ^17.0 ...
Read more >Storybook with ReactJS TypeScript | by Anny Caroline - Medium
For documentation, Storybook addon docs can be used. ... which are Storybook peer dependencies (link to storybook doc).
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Still seeing this issue too, all with latest versions
FYI react-scripts package expects a specific version of babel-loader and will fail to run if installed version is not what it wants. It seems that storybook/core can pull in a newer version (as the dependency there is more relaxed) which breaks CRA: