TIL: Astro Content Collections Are Exactly What I Wanted

A quick note on how Astro's content collections with Zod schemas make managing structured data surprisingly pleasant.

I spent years wishing for a way to manage structured content — project entries, publications, work history — without a database or a CMS. Just files, with type safety.

Astro’s Content Collections nail this. You define a Zod schema, drop YAML or MDX files into a folder, and get fully typed data at build time. If a field is missing or the wrong type, the build fails with a clear error. No runtime surprises.

For my timeline, each entry is a YAML file with type, title, organization, startDate, and so on. Adding a new project means creating a file — no UI, no API calls, no migrations.

The combination of file-based content with compile-time validation is exactly the sweet spot between “just use a JSON file” and “set up a whole CMS.” If you’re building a content-heavy static site, this is worth a look.