baisyoukin.dev

Notes are markdown files now

1 min readmeta

Adding a note used to mean editing templates/notes.html and copying a block of HTML. Now it means one file.

How it works

Every file under content/notes/ becomes a page. The filename is the URL slug, so hello.md is served at /notes/hello. The front matter at the top carries the metadata:

---
title: Notes are markdown files now
date: 2026-08-27
tag: meta
summary: One-line description used in the feed and meta tags.
draft: false
---

Only title and date are required. Set draft: true and the note is visible while HOT_RELOAD=1 is set but left out of the site, the sitemap, and the feed.

What you get for free

  • an entry on /notes, newest first
  • a page with a reading-time estimate
  • an entry in /notes/feed.xml
  • a lastmod in /sitemap.xml

Raw HTML in a note stays escaped on purpose. The site sends a strict Content Security Policy, so a note that tried to smuggle in a <script> tag would be blocked in the browser anyway — better to make it visibly inert instead.

← all notes