ea6208c1f0
* deps: bump ws * deps: bump lightningcss * deps: workerpool * deps: various types * deps: chalk * deps: globby * deps: preact * deps: tsx * deps: @floating-ui/dom * deps: esbuild * deps: types + prettier * deps: rimraf, typescript * deps: remark/rehype/unified ecosystem * format
21 lines
501 B
TypeScript
21 lines
501 B
TypeScript
import { QuartzTransformerPlugin } from "../types"
|
|
import rehypePrettyCode, { Options as CodeOptions } from "rehype-pretty-code"
|
|
|
|
export const SyntaxHighlighting: QuartzTransformerPlugin = () => ({
|
|
name: "SyntaxHighlighting",
|
|
htmlPlugins() {
|
|
return [
|
|
[
|
|
rehypePrettyCode,
|
|
{
|
|
keepBackground: false,
|
|
theme: {
|
|
dark: "github-dark",
|
|
light: "github-light",
|
|
},
|
|
} satisfies Partial<CodeOptions>,
|
|
],
|
|
]
|
|
},
|
|
})
|