Components / Code

Components / Code & Prose

Code Block

Multi-line syntax-highlighted code with copy button.

nuxt.config.ts

Inline Code

One-line copyable snippet for commands and imports.

Prose / Markdown

Renders markdown with syntax-highlighted fenced code blocks.

Preview Component

Interactive tabbed viewer demonstrating a live component next to its source code, with configurable heights.

Nested Preview

I am inside a preview!

CodeBlock API

Prop / EventTypeDefaultDescription
codestring''The source code string to display and highlight.
langstring'text'The language for syntax highlighting (e.g. "vue", "javascript").
filenamestring''Optional filename to display in the header.

InlineCode API

Prop / EventTypeDefaultDescription
codestring''The inline code snippet string.
langstring''The language for syntax highlighting.
copyablebooleantrueWhether to show the copy to clipboard button.

Prose API

Prop / EventTypeDefaultDescription
contentstring''The Markdown string to render as HTML.

PreviewCode API

Prop / EventTypeDefaultDescription
titlestring''The title displayed above the preview.
descriptionstring''The description displayed below the title.
codestring''The source code to display in the Code tab.
langstring'vue'The language for syntax highlighting in the Code tab.
previewHeightstring'auto'Fixed height for the Preview tab (e.g. "200px").
codeHeightstring'auto'Fixed height for the Code tab.