creating blog posts
on this page
This guide explains how to create blog posts for the site.
Quick Start
- Create a new
.mdxfile insrc/content/posts/ - Add the required frontmatter
- Write your post
- Build and preview
Required Frontmatter
Blog posts need this frontmatter:
blog-post.mdxyaml
---
title: 'Your Post Title'
description: 'Brief description for SEO and previews'
publishDate: 2025-08-01
author: 'Michael Bommarito' # optional, this is the default
tags: ['web-dev', 'astro']
image: '/images/posts/your-image.png' # optional
category: 'Security' # optional
draft: false # set true to hide from listings
---The full schema lives in src/content/config.ts under the posts collection.
File Naming Convention
Use the post slug alone โ no date prefix. The URL is derived from the filename:
post-slug.mdxExample: compression-as-copying.mdx publishes at /blog/compression-as-copying.
Categories
category is optional and lightly used; most posts rely on tags instead.
Adding Images
Place images in public/images/posts/ and reference them:
Or set image in the frontmatter for the post header.
Draft Posts
Set draft: true to work on posts without publishing:
---
title: 'Work in Progress'
draft: true
---Writing Tips
- Start with a compelling introduction
- Use headers to structure content
- Include code examples where relevant
- Add relevant tags for discoverability
- Keep paragraphs short and scannable
Publishing Workflow
- Write your post with
draft: true - Preview locally with
npm run dev - When ready, set
draft: false - Commit and push your changes