Skip to content

Commit

Permalink
Update docs for solid-js supporting JSX
Browse files Browse the repository at this point in the history
  • Loading branch information
wooorm committed Dec 14, 2022
1 parent 641eb91 commit caac5df
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions docs/docs/getting-started.server.mdx
Expand Up @@ -125,9 +125,7 @@ your JSX runtime.
install and configure [`@mdx-js/react`][mdx-react].
Then wrap your MDX content in a `<ThemeProvider />`
* If you’re using **Solid**,
install [`solid-jsx`][solid-jsx].
Set [`options.jsxImportSource`][options-jsximportsource] to
`'solid-jsx'`.
set [`options.jsxImportSource`][options-jsximportsource] to `'solid-js'`

Other JSX runtimes are supported by setting
[`options.jsxImportSource`][options-jsximportsource].
Expand Down Expand Up @@ -898,12 +896,12 @@ for more info.
```js path="example.js"
import {compile} from '@mdx-js/mdx'

const js = String(await compile('# hi', {jsxImportSource: 'solid-jsx', /* otherOptions… */}))
const js = String(await compile('# hi', {jsxImportSource: 'solid-js', /* otherOptions… */}))
```
</details>

Solid is supported when [`options.jsxImportSource`][options-jsximportsource] is
set to `'solid-jsx'`.
set to `'solid-js'`.

See also [¶ Vite][vite] and [¶ Rollup][rollup] which you might be using, for
more info.
Expand All @@ -926,8 +924,6 @@ See their readmes on how to configure them.

[@next/mdx]: https://github.com/vercel/next.js/tree/canary/packages/next-mdx

[solid-jsx]: https://github.com/high1/solid-jsx

[svelte-jsx]: https://github.com/kenoxa/svelte-jsx

[jsx]: #jsx
Expand Down

1 comment on commit caac5df

@vercel
Copy link

@vercel vercel bot commented on caac5df Dec 14, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

mdx – ./

v2.mdxjs.com
mdxjs.com
mdx-mdx.vercel.app
mdx-git-main-mdx.vercel.app

Please sign in to comment.