Describe the bug
Getting the following error when I include @storybook/addon-docs
:
Failed to load preset: "/absolute_path/node_modules/@storybook/addon-docs/preset.js" on level 1
ERR! Error: /absolute_path/node_modules/@storybook/addon-docs/preset.js is not a valid preset
...
My main.js
looks like this:
module.exports = {
addons: [
'@storybook/preset-create-react-app',
'storycap/register',
'@storybook/addon-knobs/register',
'@storybook/addon-docs',
],
stories: ['../src/**/*.stories.(tsx|mdx)'],
};
System:
Environment Info:
System:
OS: macOS 10.15.5
CPU: (16) x64 Intel(R) Core(TM) i9-9880H CPU @ 2.30GHz
Binaries:
Node: 10.20.1 - ~/.nvm/versions/node/v10.20.1/bin/node
Yarn: 1.22.4 - /usr/local/bin/yarn
npm: 6.14.4 - ~/.nvm/versions/node/v10.20.1/bin/npm
Browsers:
Chrome: 83.0.4103.116
Safari: 13.1.1
npmPackages:
@storybook/addon-actions: ^5.3.19 => 5.3.19
@storybook/addon-docs: ^6.0.0-beta.37 => 6.0.0-beta.37
@storybook/addon-knobs: ^5.3.19 => 5.3.19
@storybook/addon-links: ^5.3.19 => 5.3.19
@storybook/addons: ^5.3.19 => 5.3.19
@storybook/preset-create-react-app: ^3.1.2 => 3.1.2
@storybook/react: ^5.3.19 => 5.3.19
@storybook/theming: ^5.3.19 => 5.3.19
@jayarjo you can't use [email protected]
with 5.3 packages. all your @storybook/*
packages should be on the same version (except preset-create-react-app
, which is a bit confusing cc @mrmckeb @ndelangen )
@shilman maybe you should put an explicit note about that in the readme, 'cause it recommends yarn add -D @storybook/addon-docs
, without any warning.
Most helpful comment
@shilman maybe you should put an explicit note about that in the readme, 'cause it recommends
yarn add -D @storybook/addon-docs
, without any warning.