MDX fails to render docs with Vue3
See original GitHub issueI build components with Vite, Vue3, VueJsx, Typescript, Tailwindcss.
Everything works fine with Storybook in Component Story Format, but MDX Format only render Canvas and no Docs.
<-- BaseInput.stories.mdx -->
import { Meta, Story } from "@storybook/addon-docs/blocks";
import BaseInput from "./BaseInput";
<Meta title="Input/BaseInput" component={BaseInput} />
export const Template = (args) => <BaseInput {...args} />;
### Expect To See Some Docs
> But No Results
<Story
name="Text"
args={{
prefix: "Account",
}}
>
{Template.bind({})}
</Story>
<Story
name="Password"
args={{
prefix: "Password",
type: "password",
}}
>
{Template.bind({})}
</Story>
It works in Canvas

But it fails in Docs

Below is the error message from console

Issue Analytics
- State:
- Created 3 years ago
- Reactions:2
- Comments:8 (4 by maintainers)
Top Results From Across the Web
Not working with Vue 3 · Issue #1718 · mdx-js/mdx
Not working with Vue 3 When I create a Project like this: ... customized the docs and i wanted to test now already...
Read more >MDX fails to render docs with Vue3 #14201
I build components with Vite, Vue3, VueJsx, Typescript, Tailwindcss. Everything works fine with Storybook in Component Story Format, but MDX Format only render...
Read more >@mdx-js/vue | MDX
Vue context for MDX. ... This package is not needed for MDX to work with Vue. ... import {MDXProvider} from '@mdx-js/vue' import {createApp}...
Read more >Vue
Note: Parcel does not support using SFCs with Vue 2, you must use Vue 3 or later. ... <docs> This component represents the...
Read more >Error [ERR_UNSUPPORTED_ESM_URL_SCHEME]: Only ...
import rehypeHighlight from "rehype-highlight"; export default { chainWebpack: (config) => { config.module .rule("mdx") .test(/\.mdx?$/) .use ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

Added working example here https://github.com/storybookjs/storybook/pull/15383
@eXodes all vite-related issues should go to https://github.com/eirslett/storybook-builder-vite
@shilman https://github.com/mockingjet/storybook-vite-vue3-vuejsx-demo