Hello World: My First Post

· 1 min read ·

Why Astro?

Astro is a modern static site generator that helps you build fast websites with less JavaScript. It works especially well for content-focused sites like blogs.

A few things I like about it:

  • Content Collections make markdown content easy to organize
  • Zero JS by default keeps pages fast
  • Island Architecture lets you add interactivity only where it matters

A quick code example

An Astro component can be very small:

---
const greeting = 'Hello, World!';
---

<h1>{greeting}</h1>

And a little JavaScript:

const posts = await getCollection('enBlog');
const sorted = posts.sort((a, b) => b.data.date - a.data.date);

for (const post of sorted) {
  console.log(post.data.title);
}

What’s next

I’ll keep writing about technology, tools, and whatever else feels worth thinking through.