astro-frontend

Develop content-driven Astro frontends with islands architecture and zero-JS default.

5|Updated Jan 31, 2026
One-click install
npx skills add https://github.com/katsutoo/dotfiles --skill astro-frontend
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: astro-frontend
Source: https://github.com/katsutoo/dotfiles/tree/main/config/opencode/skills/astro-frontend
Command: npx skills add https://github.com/katsutoo/dotfiles --skill astro-frontend

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Astro sites often ship more JavaScript than needed, causing slower initial load and poorer performance. This Skill defines an islands-based approach to deliver static HTML and CSS by default while hydrating only interactive pieces.

Core Features & Use Cases

  • Islands Architecture: ship zero JS by default and hydrate only necessary components.
  • Content Collections: leverage Astro's content system for structured, typed data.
  • Astro Actions: server-side patterns for validated, scalable server functions.
  • Use Case: blogs, marketing sites, docs, and e-commerce storefronts that require fast performance and selective interactivity.

Quick Start

Create a new Astro project configured for islands-based hydration and start building a content-driven site.

Frequently Asked Questions about astro-frontend

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I ship zero-JS by default in an Astro frontend?

Astro frontends ship zero-JS by default using an islands architecture that delivers static HTML and CSS, hydrating only the specific interactive components needed. This approach prevents unnecessary JavaScript from slowing down your site's initial load times.

How do I use Content Collections for structured data in Astro?

Astro Content Collections leverage a built-in content system to manage structured, typed data for your site. This feature allows you to define schemas for your content, ensuring type safety and easier data management across blogs, docs, and storefronts.

When should I use Astro islands architecture for a content-driven site?

Astro islands architecture suits content-driven sites like blogs, marketing pages, docs, and e-commerce storefronts that demand fast load times. Use it when you need selective interactivity without shipping a heavy JavaScript bundle to the client.

Does this Astro frontend approach work with TypeScript strict mode and server-side rendering?

Yes, this approach satisfies requirements for TypeScript strict mode and server-side rendering with islands hydration. It combines Astro Actions for validated server functions with static generation to maintain type safety and scalable backend logic.

What's the best way to add server-side functions to a static Astro site?

Astro Actions provide server-side patterns for validated, scalable server functions within your static site. They allow you to execute secure backend logic directly from your components, bridging the gap between zero-JS static output and dynamic server processing.

Why does my Astro site ship more JavaScript than needed?

Astro sites ship more JavaScript than needed when components are hydrated globally rather than selectively. Defining an islands-based approach ensures the site delivers static HTML and CSS by default, hydrating only the necessary interactive pieces to improve performance.