30 lines
794 B
TypeScript
30 lines
794 B
TypeScript
|
|
import { defineConfig } from "@solidjs/start/config";
|
||
|
|
import pkg from "@vinxi/plugin-mdx";
|
||
|
|
import tailwindcss from "@tailwindcss/vite";
|
||
|
|
import rehypePrismPlus from "rehype-prism-plus";
|
||
|
|
import rehypeMdxCodeProps from "rehype-mdx-code-props";
|
||
|
|
import remarkFrontmatter from "remark-frontmatter";
|
||
|
|
import { blogPostsPlugin } from "./build-helpers/blogPostsPlugin";
|
||
|
|
|
||
|
|
const { default: mdx } = pkg;
|
||
|
|
|
||
|
|
export default defineConfig({
|
||
|
|
extensions: ["mdx", "md"],
|
||
|
|
vite: () => ({
|
||
|
|
plugins: [
|
||
|
|
tailwindcss(),
|
||
|
|
blogPostsPlugin(),
|
||
|
|
mdx.withImports({})({
|
||
|
|
jsx: true,
|
||
|
|
jsxImportSource: "solid-js",
|
||
|
|
providerImportSource: "solid-mdx",
|
||
|
|
remarkPlugins: [remarkFrontmatter],
|
||
|
|
rehypePlugins: [
|
||
|
|
[rehypePrismPlus, { ignoreMissing: true }],
|
||
|
|
rehypeMdxCodeProps,
|
||
|
|
],
|
||
|
|
}),
|
||
|
|
],
|
||
|
|
}),
|
||
|
|
});
|