[Bug] React.jsx: type is invalid
See original GitHub issueDescribe the Bug
Sorry for bothering, but i just found an inevitable exception when i start my vue3 project without using any mdx file with @storybook/builer-vite@0.1.38
or laster.
the web page crashed due to this problem, which was fixed by adding some lines in main.js:
async viteFinal(config) {
// ignore react plugins
config.plugins = config.plugins.flat().filter(p => !p.name.includes('react'))
return config
}
i didn’t use any features about mdx. but I need to ignore the react plugins, which confused me.
Link to Minimal Reproducible Example
I’ve made the reproduction with codesanbox
at storybook-bug-reproduce, you can check for more info. After the demo’s lanuching, you’ll find something wrong as below in console.
What version of vite
are you using?
^3.1.0(latest)
System info and storybook versions
System: OS: macOS 12.5.1 CPU: (8) arm64 Apple M1 Binaries: Node: 16.16.0 - ~/.nvm/versions/node/v16.16.0/bin/node Yarn: 1.22.19 - ~/.pnpm/yarn npm: 8.11.0 - ~/.nvm/versions/node/v16.16.0/bin/npm Browsers: Chrome: 104.0.5112.101 Safari: 15.6.1 npmPackages: @storybook/addon-actions: ^6.5.10 => 6.5.10 @storybook/addon-backgrounds: ^6.5.10 => 6.5.10 @storybook/addon-docs: ^6.5.10 => 6.5.10 @storybook/addon-essentials: ^6.5.10 => 6.5.10 @storybook/addon-links: ^6.5.10 => 6.5.10 @storybook/addon-measure: ^6.5.10 => 6.5.10 @storybook/addon-outline: ^6.5.10 => 6.5.10 @storybook/builder-vite: ^0.2.2 => 0.1.36 @storybook/client-api: ^6.5.10 => 6.5.10 @storybook/client-logger: ^6.5.10 => 6.5.10 @storybook/core-common: ^6.5.10 => 6.5.10 @storybook/node-logger: ^6.5.10 => 6.5.10 @storybook/vue3: ^6.5.10 => 6.5.10
Participation
- I am willing to submit a pull request for this issue.
Issue Analytics
- State:
- Created a year ago
- Comments:11 (4 by maintainers)
@IanVS 😄 I made some updates about the meta info of this issue, tried and succeeded to add an online example with codesandbox, which you can easily get start. Please scroll to the top of the page and see the description of the issue.
Of course. I tried to create a demo with codesandbox, but I failed, I’ll try it again later with some other ways