feat: add training list page, training page and markdown content
This commit is contained in:
parent
3dd584fcf4
commit
e19dbb71cd
16 changed files with 586 additions and 15 deletions
9
lib/markdownToHTML.ts
Normal file
9
lib/markdownToHTML.ts
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
import { remark } from 'remark'
|
||||
import html from 'remark-html'
|
||||
|
||||
const markdownToHTML = async (markdown: string) => {
|
||||
const result = await remark().use(html).process(markdown)
|
||||
return result.toString()
|
||||
}
|
||||
|
||||
export default markdownToHTML
|
||||
Reference in a new issue