Closed yCobanoglu closed 3 years ago
import unified from 'unified' import remarkParse from 'remark-parse' import remark2rehype from 'remark-rehype' import stringify from 'rehype-stringify' import remarkSubSuper from "remark-sub-super" export default async function markdown2Html(markdown: string): Promise<string> { const file = await unified() .use(remarkParse) .use(remarkSubSuper) .use(remark2rehype) .use(stringify) .process(markdown) return String(file) }
Throws the following typescript error.
See https://github.com/zestedesavoir/zmarkdown/issues/416
Closing as this was answered with further comments.
Feel free to reopen an issue if you need.
Throws the following typescript error.![Screenshot_2021-06-07_18-15-27](https://user-images.githubusercontent.com/56864644/121054370-91461380-c7bc-11eb-995d-a9a0fb82bcef.png)