Skip to content

Vue 3 + vite-plugin-ssr + MDX? #2090

Answered by ChristianMurphy
AlanMorel asked this question in Q&A
Discussion options

You must be logged in to vote

Check out the mdx getting started guide for vue: https://mdxjs.com/docs/getting-started/#vue
in particular the notes from the example:

Vue 3 is supported when using their custom Babel JSX transformer (@vue/babel-plugin-jsx) and configuring @mdx-js/mdx, @mdx-js/rollup, or @mdx-js/loader with jsx: true. You can optionally install and configure @mdx-js/vue, which allows for context based component passing.

the error you shared:

Error: Failed to parse source for import analysis because the content contains invalid JS syntax. You may need to install appropriate plugins to handle the .mdx file format, or if it's an asset, add "**/*.mdx" to `assetsInclude` in your configuration.

sounds like i…

Replies: 1 comment 6 replies

Comment options

You must be logged in to vote
6 replies
@ChristianMurphy
Comment options

@ChristianMurphy
Comment options

@AlanMorel
Comment options

@wooorm
Comment options

@AlanMorel
Comment options

Answer selected by AlanMorel
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants