Skip to content

[Feature]: Enable katex for math formula #158

@zhoubin-me

Description

@zhoubin-me

I have updated mdsvex.config.js as like:

import { defineMDSveXConfig as defineConf } from 'mdsvex';
import rehypeKatexSvelte from 'rehype-katex-svelte';
import remarkMath from 'remark-math';
...

const config = defineConf({
	remarkPlugins: [remarkMath],
	rehypePlugins: [
		[
			rehypeKatexSvelte,
			{
				output: 'mathml'
			}
		]
	]
});

But still cannot render math correctly, any clue?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions