render markdown page

This commit is contained in:
MapleLeaf
2021-12-31 15:14:59 -06:00
committed by Darius
parent 989c3a573a
commit f603bdd7ba
4 changed files with 1016 additions and 6 deletions

View File

@@ -1,6 +1,21 @@
import rehypePrism from "@mapbox/rehype-prism"
import react from "@vitejs/plugin-react"
import remarkFrontmatter from "remark-frontmatter"
import { defineConfig } from "vite"
import xdm from "xdm/rollup"
export default defineConfig({
plugins: [react()],
plugins: [
react(),
xdm({
remarkPlugins: [remarkFrontmatter],
rehypePlugins: [rehypePrism],
}),
],
resolve: {
alias: {
// https://github.com/brillout/vite-plugin-mdx/issues/44#issuecomment-974540152
"react/jsx-runtime": "react/jsx-runtime.js",
},
},
})