Skip to content
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

[Bug] SB v7 docs broken without storyStoreV7 #492

Closed
1 task
Niznikr opened this issue Sep 2, 2022 · 9 comments
Closed
1 task

[Bug] SB v7 docs broken without storyStoreV7 #492

Niznikr opened this issue Sep 2, 2022 · 9 comments
Labels
bug Something isn't working

Comments

@Niznikr
Copy link

Niznikr commented Sep 2, 2022

What version of vite are you using?

3.0.0

System info and storybook versions

System:
OS: macOS 12.5.1
CPU: (10) arm64 Apple M1 Pro
Binaries:
Node: 16.15.0 - /usr/local/bin/node
Yarn: 1.22.17 - /opt/homebrew/bin/yarn
npm: 8.5.5 - /usr/local/bin/npm
Browsers:
Chrome: 105.0.5195.52
Firefox: 104.0.1
Safari: 15.6.1
npmPackages:
@storybook/addon-a11y: ^7.0.0-alpha.28 => 7.0.0-alpha.28
@storybook/addon-actions: ^7.0.0-alpha.28 => 7.0.0-alpha.28
@storybook/addon-backgrounds: ^7.0.0-alpha.28 => 7.0.0-alpha.28
@storybook/addon-docs: ^7.0.0-alpha.28 => 7.0.0-alpha.28
@storybook/addon-essentials: ^7.0.0-alpha.28 => 7.0.0-alpha.28
@storybook/addon-highlight: ^7.0.0-alpha.28 => 7.0.0-alpha.28
@storybook/addon-interactions: ^7.0.0-alpha.28 => 7.0.0-alpha.28
@storybook/addon-measure: ^7.0.0-alpha.28 => 7.0.0-alpha.28
@storybook/addon-outline: ^7.0.0-alpha.28 => 7.0.0-alpha.28
@storybook/addons: ^7.0.0-alpha.28 => 7.0.0-alpha.28
@storybook/api: ^7.0.0-alpha.28 => 7.0.0-alpha.28
@storybook/channel-postmessage: ^7.0.0-alpha.28 => 7.0.0-alpha.28
@storybook/channel-websocket: ^7.0.0-alpha.28 => 7.0.0-alpha.28
@storybook/cli: ^7.0.0-alpha.28 => 7.0.0-alpha.28
@storybook/client-api: ^7.0.0-alpha.28 => 7.0.0-alpha.28
@storybook/client-logger: ^7.0.0-alpha.28 => 7.0.0-alpha.28
@storybook/components: ^7.0.0-alpha.28 => 7.0.0-alpha.28
@storybook/core-client: ^7.0.0-alpha.28 => 7.0.0-alpha.28
@storybook/core-events: ^7.0.0-alpha.28 => 7.0.0-alpha.28
@storybook/preview-web: ^7.0.0-alpha.28 => 7.0.0-alpha.28
@storybook/react: ^7.0.0-alpha.28 => 7.0.0-alpha.28
@storybook/react-vite: ^7.0.0-alpha.28 => 7.0.0-alpha.28
@storybook/testing-library: ^0.0.13 => 0.0.13
@storybook/theming: ^7.0.0-alpha.28 => 7.0.0-alpha.28

Describe the Bug

This is for a pnpm monorepo project migrating from 7.0.0-alpha.10 webpack React to 7.0.0-alpha.28 with the Vite framework. I have storyStoreV7 set to false due to TypeError: Failed to fetch error. Everything is working great using the Vite framework except for the new Docs pages that are now on the sidebar with the stories:

Screen Shot 2022-09-02 at 8 21 39 AM

I've tried removing addons, tweaking any configuration but nothing seems to help. Any suggestions?

Link to Minimal Reproducible Example

No response

Participation

  • I am willing to submit a pull request for this issue.
@Niznikr Niznikr added the bug Something isn't working label Sep 2, 2022
@IanVS
Copy link
Member

IanVS commented Sep 2, 2022

Thanks for reporting this. I don't see @storybook/builder-vite in the list of dependencies you listed out above. What version are you using?

@Niznikr
Copy link
Author

Niznikr commented Sep 2, 2022

Looks like @storybook/react-vite 7.0.0-alpha.28 (which I've installed) has @storybook/builder-vite 7.0.0-alpha.28 as a direct dependency.

@IanVS
Copy link
Member

IanVS commented Sep 2, 2022

Ah, you're right. I'm still getting used to this myself. :-D

I don't suppose you'd be able to share a minimal reproduction, would you? I'd love to figure out what's going on, and I haven't seen this before.

Until then, what does your .storybook/main.js look like? Particularly the stories.

@IanVS
Copy link
Member

IanVS commented Sep 2, 2022

Nevermind, I can see it myself when disabling storyStoreV7. Thanks again for reporting!

@Niznikr
Copy link
Author

Niznikr commented Sep 2, 2022

My pleasure! Thanks for the quick response. I might report the TypeError: Failed to fetch error with storyStoreV7 set to true on Storybook's side as it happens for both Webpack and Vite versions.

@IanVS
Copy link
Member

IanVS commented Sep 2, 2022

Please do! You'll definitely want to use storyStoreV7, especially with Vite, so we should be sure to get that fixed.

@tmeasday There's an issue here with the V6 store that I could use your help in troubleshooting. It reproduces in a new vite storybook project when disabling storyStoreV7.

@IanVS IanVS changed the title [Bug] SB v7 docs page throws "Couldn't find story matching..." [Bug] SB v7 docs broken without storyStoreV7 Sep 2, 2022
@tmeasday
Copy link
Member

tmeasday commented Sep 7, 2022

Thanks folks! PR here: storybookjs/storybook#19127

@IanVS
Copy link
Member

IanVS commented Sep 19, 2022

@Niznikr can you try upgrading to the latest 7.0 alpha and confirm that your issue is solved? I'm going to close this in the meantime, but let us know if you're still having trouble. Thanks!

@IanVS IanVS closed this as completed Sep 19, 2022
@Niznikr
Copy link
Author

Niznikr commented Sep 21, 2022

That fixed it thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants