A high-performance markdown parser and renderer with Vue & React components support.
A high-performance markdown parser and renderer with Vue & React components support.
npm install comark
# or
pnpm add comark
<script setup lang="ts">
import { Comark } from 'comark/vue'
import cjk from '@comark/cjk'
import math from '@comark/math'
import { Math } from '@comark/math/vue'
const chatMessage = ...
</script>
<template>
<Comark :components="{ Math }" :plugins="[cjk(), math()]">{{ chatMessage }}</Comark>
</template>
import { Comark } from 'comark/react'
import cjk from '@comark/cjk'
import math from '@comark/math'
import { Math } from '@comark/math/react'
function App() {
const chatMessage = ...
return <Comark components={{ Math }} plugins={[cjk(), math()]}>{chatMessage}</Comark>
}
Made with β€οΈ
Published under MIT License.
We use cookies
We use cookies to analyze traffic and improve your experience. You can accept or reject analytics cookies.