8 lines
223 B
TypeScript
8 lines
223 B
TypeScript
|
import { remark } from "remark";
|
||
|
import html from "remark-html";
|
||
|
|
||
|
export default async function convertMarkdown(markdown: string) {
|
||
|
const result = await remark().use(html).process(markdown);
|
||
|
return result.toString();
|
||
|
}
|