Rebuilding my site for speed

· 1 min read

A white lightning bolt inside a circle on a dark blue and purple background

This is a sample post. Replace it with your own, or delete it.

Each post lives in its own folder in src/content/blog/, named with the publish date first: 2026-11-17-hello-world/index.md (or index.mdx). The date keeps the folders in order on disk and never appears in the URL. The slug in the frontmatter sets the URL, so this one lives at /blog/hello-world.

What’s in the frontmatter

  • slug is required and becomes the URL: lowercase letters, numbers and hyphens.
  • title and description are required. They become the page title, the meta description and the social card. The build fails if they run long enough to get cut off in search results.
  • pubDate must match the date in the folder name. It and an optional updatedDate appear on the page, in the RSS feed and in the structured data.
  • cover is an optional image that sits next to index.md in the post’s folder (cover: ./cover.jpg). It becomes the banner at the top of the post, the thumbnail next to the post on the blog page and the home page, and the share image. Astro crops and resizes it for each, so one landscape image at least 1600px wide is enough. Keep the subject near the middle. Add coverAlt to describe it.
  • Set featured: true to list the post on the home page. Posts without it appear only on the blog page.
  • Set draft: true to keep a post off the live site. It still shows when you run npm run dev.
const fast = true;

← All posts