-
-
Notifications
You must be signed in to change notification settings - Fork 9.4k
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
addon-docs: Failed prop type: Invalid prop viewMode
of value docs
supplied to Preview
, expected one of ["story","info"].
#7988
Comments
viewMode
of value docs
supplied to Preview
, expected one of ["story","info"].viewMode
of value docs
supplied to Preview
, expected one of ["story","info"].
@alisonsayarath That error looks like you're somehow using an old version of Storybook. Can you:
Also, I'd recommend upgrading to |
Thanks for the quick answer! And it shows two versions :
We have two version because we use a custom CRA (so we had to fork the 5.1.11 to make our command |
@shilman yeah, it's been awhile seeing these errors. Probably when addon architecture or the routing architecture was changed. Maybe little bit more info from #7241
|
@alisonsayarath why did you need to fork it? that will def cause problems. docs should be stable release in the next two weeks. |
@lonyele Yeah those routes were hard-coded in 5.0 due to lack of time. And I think they are hard-coded again in 5.2. But we expect our users to use the same version of our libraries, and don't make guarantees if they are not. This is not pure semver, but practically speaking it's worked for us so far aside from this kind of case (e.g. people mixing 5.1 & 5.2 together), which unfortunately happens fairly often. |
I change all in the same version on {
// ...
"@storybook/addon-actions": "^5.2.0-rc.5", // was 5.1.11
"@storybook/addon-docs": "^5.2.0-rc.5",
"@storybook/addon-links": "^5.2.0-rc.5", // was 5.1.11
"@storybook/addons": "^5.2.0-rc.5", // was 5.1.11
"@storybook/react": "^5.2.0-rc.5" // was 5.1.11
// ...
} |
Oups, sorry for the late answer. We have multiple CRA base config modes. |
Describe the bug
When using addon-docs with MDX, my component in the Canvas tab is shown, but nothing in the Docs tab shows.
To Reproduce
Configure the new Storybook beta with
docs-addon
while adding those presets :Versions :
Screenshots
Story
base.story.mdx
:Config
config.js
:My component shows well in the Canvas tab, however, when I go to the Docs tab, I am having the following errors :
The text was updated successfully, but these errors were encountered: