How to use Markdown content in Nuxt 2 and Typescript
Markdown in Nuxt
Installing dependencies
Install Nuxt's Markdown module.
Install Markdown attrs dependency.
Install Markdown div dependency.
Add Markdown types in tsconfig.json
// tsconfig.json
"types": [
"@nuxtjs/markdownit"
]
Render content in the template:
<!-- content is where your content that needs to be render -->
<div v-html="$md.render(content)"></div>