How this site works
This site starts with a folder of text files and a small script that turns them into HTML. The public pages have no framework or database, and no application JavaScript to load.
The whole build is one command:
npm run build
A few things it does that you might not notice:
- Supporting browsers can prerender internal links before you open them.
- It follows your system’s light or dark setting.
- Drafts stay out of the public build, RSS feed, and sitemap.
- Local images get their dimensions filled in at build time, so the page can reserve space before they load.
A room for writing #
I can edit the Markdown files directly, or open the local writing room:
npm run write
It has an editor, a preview, autosave, and a draft toggle. It also lets me edit the home page and site settings, add standalone pages, and paste images into an entry.
The editor runs locally. The deployed site only contains the built public files.
A small publishing check #
The build checks for unfinished template copy and missing local file links before it writes the public site. That catches mistakes like a placeholder email address or a link to an image I forgot to add.
The output includes an RSS feed, a sitemap, search metadata, and a page for missing addresses. It can be served by a plain static web server.
I like that I can follow the path from a sentence in a text file to the page in the browser. It’s a small enough system to keep changing without turning the site itself into the main project.