Markdown Writing Demo

Code Highlighting

Inline code const x = 1 looks like this. Hover the top-right corner of a code block to copy it with one click:

// Quick sort
function quickSort(arr) {
  if (arr.length <= 1) return arr;
  const pivot = arr[0];
  const left = arr.slice(1).filter((x) => x < pivot);
  const right = arr.slice(1).filter((x) => x >= pivot);
  return [...quickSort(left), pivot, ...quickSort(right)];
}

console.log(quickSort([3, 6, 1, 8, 2]));
def hello(name: str) -> str:
    return f"Hello, {name}!"

Tables

Feature Status Notes
Dark mode ✅ Remembers your preference
Full-text search ✅ Powered by Pagefind
Comments 🔧 Enabled after configuring Giscus

Blockquotes

Writing is the best way to think.

— Some blogger

Lists

  • Unordered lists work
  • So do ordered lists
  1. Step one
  2. Step two
  3. Step three
📤 Share:

💬 Comments not configured yet (fill in Giscus info in consts.ts to enable)