-
-
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
[Bug]: ReferenceError: mdx is not defined #21023
Comments
same issue |
Try to upgrade the Storybook to v7 beta: npm create vite@latest # base on react and typescript
npm install @storybook/builder-vite@next --save-dev # next version
npx storybook@next init # next version
npm run storybook beta-45 works for me! Environment Info:
System:
OS: macOS 13.1
CPU: (8) arm64 Apple M1
Binaries:
Node: 16.14.2 - ~/.nvm/versions/node/v16.14.2/bin/node
Yarn: 1.22.19 - ~/.yarn/bin/yarn
npm: 8.5.0 - ~/.nvm/versions/node/v16.14.2/bin/npm
Browsers:
Chrome: 109.0.5414.119
Safari: 16.2
npmPackages:
@storybook/addon-essentials: ^7.0.0-beta.45 => 7.0.0-beta.45
@storybook/addon-interactions: ^7.0.0-beta.45 => 7.0.0-beta.45
@storybook/addon-links: ^7.0.0-beta.45 => 7.0.0-beta.45
@storybook/blocks: ^7.0.0-beta.45 => 7.0.0-beta.45
@storybook/builder-vite: ^7.0.0-beta.45 => 7.0.0-beta.45
@storybook/testing-library: ^0.0.14-next.1 => 0.0.14-next.1
@storybook/vue3: ^7.0.0-beta.45 => 7.0.0-beta.45
@storybook/vue3-vite: ^7.0.0-beta.45 => 7.0.0-beta.45 |
same issue |
see here: #21023 (comment) |
Same here. I know @zhyd1997 will tell me to upgrade but for some of us, we can't just upgrade (yet). So if we can get a fix or even a workaround for this will be helpful :( |
did remove the field below work for you? // main.ts
"features": {
"storyStoreV7": true
} not tested! |
yeah tried that as well. Didn't work. |
maybe some deps broken, need to ping deep deps specific version 👀 not sure! |
I have tried this one as well but didnt work :( |
Looks like this is going to get fixed in builder-vite: storybookjs/builder-vite#557 |
@IanVS is this handled with our most recent set of changes? |
Yes, although because of the way we depend on |
This issue looks like it is actually about the 6.5 builder. The fix has been released there, so please update to the latest |
For me it was |
Describe the bug
When a new project is based on Vite, React, TypeScript, StoryBook, and the storybook files have stories.mdx extensions, at the console reference error during the running storybook. The mdx story isn't shown.
To Reproduce
System
Additional context
If the project based on CRA it is working correct.
The text was updated successfully, but these errors were encountered: