Welcome
VMarkdownPreview
Vuero ship <VMarkdownPreview />
component that converts Markdown source code to HTML and highlights code blocks using shiki.
This component uses unifiedjs
, a powerful toolkit for processing and manipulating text and markdown files, to parse and transform the Markdown source code. unifiedjs has a number of benefits, including:
- Support for a wide range of plugins that enable additional functionality,
such as syntax highlighting and code formatting. - Extensibility, allowing developers to create custom plugins to meet their specific needs
shiki
is a high-performance syntax highlighting library that is used to add syntax highlighting to code blocks in the generated HTML. Some benefits of using shiki include:
- Fast and lightweight, with a small bundle size
- Supports a wide range of programming languages
- Customizable, allowing developers to choose from a variety of color schemes and styles
VMarkdownPreview Props
Here is the full props available for <VMarkdownPreview />
component:
Props | Default | Type |
---|---|---|
source | '' | string |
max-width | undefined | small , medium , fullwidth |
size | undefined | small , medium , large |
shiki | undefined | { theme: string | { light: string, dark: string } langs: string[] } |
placeholder | { height: '100px' } | VPlaceload props |