Sample 05: Code Blocks
Fenced code blocks with syntax highlighting.
Code Blocks
TypeScript
interface Post {
id: string;
title: string;
tags: string[];
}
function getPost(id: string): Post | undefined {
return posts.find((p) => p.id === id);
}
Bash
# Install dependencies
npm install
# Run dev server
npm run dev --workspace=notro-tail
JSON
{
"name": "notro-tail",
"version": "0.0.1",
"type": "module"
}
Plain text (no language)
This is plain text without syntax highlighting.
Line two.