DEV Community

Cover image for Why I like Astro
Cassidy Williams
Cassidy Williams

Posted on • Originally published at contenda.co on

Why I like Astro

My blog, our website at Contenda, and Share Pear are all built with Astro!

It has quickly become one of my favorite frameworks. Here’s why!

  1. Comfortably Familiar: Astro doesn’t require you to learn new lifecycle methods or other complex concepts. It brings back the simplicity of web development, reminiscent of when we all started dabbling with HTML and CSS. You can build with plain old HTML and CSS and add other stuff as needed.

  2. Flexibility: Want to use React or Svelte for certain components on your page? You can do that with Astro. It allows you to pull in different libraries and frameworks, giving you the flexibility to use the tools you prefer.

  3. Minimalist by Design: Astro is intentionally minimal. It only runs certain things when you tell it to, which helps to avoid unnecessary bloat on your page. This design philosophy aligns with the idea of making websites faster by not adding too much rather than trying to optimize heavy pages.

  4. File-based Routing: Astro does file-based routing, which means you just add the page to the folder and it’s done. You can make your app as React-heavy as you want without having to set up routing.

  5. Server-side Rendering (SSR) and Static Generation: Astro supports both SSR and static generation. Whether you prefer to upload something to a CDN or want to handle things server-side, Astro has you covered.

  6. Built-in Pagination: Astro has a built-in function called getStaticPaths that creates static paths based on whatever function you pass into it. This means you can create and paginate through pages with ease.

Astro brings a lot of exciting features to the table, offering a blend of simplicity, flexibility, and performance. It’s a tool that certainly warrants your attention if you’re in the web development space.

As always, I’m open to discussions and answering any questions you might have about Astro. Let’s explore this new framework together!

Top comments (2)

Collapse
 
jonyee profile image
Jonathan

Most article I've read, recommends Astro only for content-focus / static sites. Frameworks like nextjs and remix are too opinionated. Would you say Astro would be a good fit for application-focus / interaction-heavy / state / dynamic data type of projects?

Collapse
 
cassidoo profile image
Cassidy Williams

Yes! I personally really like it for those kinds of interaction-heavy projects, because all of the UI libraries that you can want to use are opt-in by default!