Communitygithub.com

Astro Islands Architect

콘텐츠 중심 사이트 구축 시 SSG/SSR/하이브리드 결정, 클라이언트 지시어(idle/visible/load/media) 선택, 타입-세이프 스키마로 콘텐츠 컬렉션 구성, React/Vue/Solid/Svelte 컴포넌트 통합, Next.js에서 마이그레이션 시 사용합니다.

Astro Islands Architect란 무엇인가요?

이 스킬은 Astro의 아일랜드 아키텍처를 활용하여 콘텐츠 중심 웹사이트(마케팅, 문서, 블로그)의 성능을 최적화하는 방법을 설명합니다. Astro는 기본적으로 정적 HTML을 생성하고 JavaScript가 필요한 컴포넌트만 '아일랜드'로 선택적으로 하이드레이션하여 번들 크기를 크게 줄입니다. 주요 기능으로는 client:load, client:idle, client:visible 등의 클라이언트 지시어를 상황에 맞게 선택하는 방법, Zod 스키마를 통해 타입-세이프한 콘텐츠 컬렉션 구성, React/Vue/Svelte/Solid 등 여러 프레임워크를 동일 프로젝트에서 혼용하는 방법, Astro 4+의 서버 아일랜드(server:defer), 이미지 최적화(@astrojs/assets), 뷰 트랜지션(View Transitions), MDX 레이아웃 등을 다룹니다. 또한 client:load 남용, 데이터 패칭을 클라이언트 컴포넌트에서 수행하는 경우, 타입 없는 프론트매터 등 흔한 안티패턴을 진단하고 해결책을 제시합니다. Astro는 SPA보다는 콘텐츠 위주 사이트에 적합하며, Next.js/Remix가 더 적합한 경우를 명확히 구분합니다.

지원 대상~Claude Code~Codex CLI~Cursor
npx skills add https://github.com/curiositech/windags-skills/tree/HEAD/skills/astro-islands-architect

즐겨 사용하는 AI에게 물어보기

이 에이전트 스킬이 미리 로드된 새 채팅을 엽니다.

문서

Astro Islands Architect은(는) 무엇을 하나요?

Astro는 "기본적으로 HTML을 제공하고, JS가 필요한 부분만 하이드레이션"합니다. 마케팅, 문서, 콘텐츠 중심 사이트의 경우 React/Next.js보다 훨씬 작은 번들을 생성합니다. 핵심 과제는 어떤 컴포넌트를 정적으로 렌더링하고 어떤 것을 아일랜드로 만들지 선택하는 것입니다.

사용 시기

  • 마케팅 사이트, 블로그, 문서 포털 — 콘텐츠가 핵심 제품일 때
  • 클라이언트 JS가 과도하게 많은 Next.js 마케팅 사이트에서 마이그레이션할 때
  • 멀티-프레임워크 — React 컴포넌트 라이브러리를 Vue 또는 Svelte 컴포넌트와 함께 사용할 때
  • MDX + 타입-세이프 프론트매터로 콘텐츠를 많이 작성할 때
  • SPA 없이 페이지 간 뷰 트랜지션을 사용할 때

핵심 기능

페이지 구조

---
// src/pages/blog/[slug].astro — 프론트매터는 빌드/SSR 시점에 실행됩니다
import { getCollection, getEntry } from 'astro:content';
import Layout from '../../layouts/Default.astro';
import Newsletter from '../../components/Newsletter.tsx';

export async function getStaticPaths() {
  const posts = await getCollection('blog');
  return posts.map((p) => ({ params: { slug: p.slug }, props: { post: p } }));
}

const { post } = Astro.props;
const { Content } = await post.render();
---
<Layout title={post.data.title}>
  <h1>{post.data.title}</h1>
  <article><Content /></article>

  {/* 아일랜드 — 이 컴포넌트만 JS를 전송합니다 */}
  <Newsletter client:visible />
</Layout>

--- fence 내의 코드는 서버 코드입니다. <...> 안에서는 기본적으로 정적 HTML이 생성됩니다. client:* 지시어가 있는 컴포넌트가 아일랜드가 됩니다.

클라이언트 지시어 — 올바른 선택

지시어하이드레이션 시점사용 예
client:load페이지 로드 시화면 상단의 인터랙티브 요소 (장바구니, 검색)
client:idle브라우저가 유휴 상태일 때중요하지 않은 인터랙티브 요소 (채팅 위젯)
client:visible뷰포트에 스크롤되어 보일 때화면 아래쪽 요소 (뉴스레터 가입, 댓글)
client:media="(min-width: 768px)"미디어 쿼리 일치 시데스크톱 전용 위젯
client:only="react"SSR 생략; 클라이언트 전용 렌더링마운트 시 브라우저 API가 필요한 컴포넌트

client:idle은 대부분의 중요하지 않은 아일랜드에 적합한 기본값입니다. client:load는 무거운 도구이므로 꼭 필요한 경우에만 사용하세요.

콘텐츠 컬렉션

// src/content/config.ts
import { defineCollection, z } from 'astro:content';

const blog = defineCollection({
  type: 'content',                    // markdown/MDX 파일
  schema: z.object({
    title: z.string().max(120),
    description: z.string().max(160),
    date: z.coerce.date(),
    tags: z.array(z.string()).default([]),
    draft: z.boolean().default(false),
    cover: z.object({ src: z.string(), alt: z.string() }).optional(),
  }),
});

export const collections = { blog };

이제 getCollection('blog')는 완전히 타입이 지정됩니다. 프론트매터 오류는 프로덕션에 도달하지 못하고 빌드 시점에 실패합니다.

const posts = (await getCollection('blog'))
  .filter((p) => !p.data.draft)
  .sort((a, b) => +b.data.date - +a.data.date);

멀티-프레임워크

npx astro add react vue svelte
---
import ReactSearch from '../components/Search.tsx';
import VueChart from '../components/Chart.vue';
import SvelteToggle from '../components/Toggle.svelte';
---
<ReactSearch client:idle />
<VueChart client:visible />
<SvelteToggle client:load />

각 프레임워크의 런타임은 별도로 번들링되며, 해당 프레임워크를 사용하는 페이지에서만 로드됩니다. 대부분 정적인 문서 사이트의 경우, 대부분의 페이지에 React JS를 전혀 전송하지 않을 수도 있습니다.

서버 아일랜드 (Astro 4+)

<Layout>
  <Header />
  <PersonalizedRecommendations server:defer>
    <p slot="fallback">추천 로딩 중...</p>
  </PersonalizedRecommendations>
  <Footer />
</Layout>

server:defer는 페이지 나머지 부분을 즉시 렌더링하고, 지연된 컴포넌트의 HTML은 별도 요청을 통해 스트리밍합니다. 페이지 전체를 SSR로 강제하지 않으면서 개인화된 콘텐츠를 제공할 때 유용합니다.

이미지 최적화

---
import { Image } from 'astro:assets';
import cover from '../assets/cover.jpg';
---
<Image src={cover} alt="커버 사진" widths={[400, 800, 1200]} sizes="(max-width: 768px) 400px, 1200px" />

Astro는 srcset을 생성하고, Sharp를 사용해 크기를 조정하며, 필요한 크기만 전송합니다. 전체 최적화를 위해 이미지는 src/assets/ 아래에 두세요. public/은 처리되지 않습니다.

뷰 트랜지션

---
import { ViewTransitions } from 'astro:transitions';
---
<html>
  <head>
    <ViewTransitions />
  </head>
  ...
</html>
<a href="/about" transition:name="hero">소개</a>

SPA 없이 페이지 간 전환. 브라우저가 대부분의 작업을 처리하고, Astro는 요소 매칭을 조정합니다.

MDX와 컴포넌트

---
title: My post
date: 2026-04-30
---

import Callout from '../../components/Callout.astro';

# {frontmatter.title}

<Callout type="warn">
이것은 서버 측에서 렌더링된 경고입니다. JS가 필요 없습니다.
</Callout>

MDX에서 임포트된 컴포넌트는 아일랜드가 아닌 경우 빌드/SSR 시점에 실행됩니다.

하이브리드 SSR

// astro.config.mjs
import { defineConfig } from 'astro/config';
import cloudflare from '@astrojs/cloudflare';

export default defineConfig({
  output: 'hybrid',
  adapter: cloudflare(),
});
---
// src/pages/api/search.ts — 엣지에서 실행
import { search } from '../../db';
import type { APIRoute } from 'astro';

export const prerender = false;

export const GET: APIRoute = async ({ request }) => {
  const url = new URL(request.url);
  const q = url.searchParams.get('q') ?? '';
  const results = await search(q);
  return new Response(JSON.stringify(results), { headers: { 'content-type': 'application/json' } });
};

prerender = false는 해당 경로를 SSR로 전환합니다. 사이트의 나머지는 정적 상태를 유지합니다.

안티패턴

모든 곳에서 client:load 사용

증상: Lighthouse JS 번들이 비대해지고 Astro의 하이드레이션 이점이 사라짐. 진단: 엔지니어들이 가장 익숙한 client:load를 기본으로 사용함. 해결: 기본값을 client:idle 또는 client:visible로 설정하고, client:load는 화면 상단의 인터랙티브 요소에만 사용.

클라이언트 컴포넌트에서 데이터 패칭

증상: 모든 페이지에 로딩 스피너가 나타나고 SEO에 악영향. 진단: 데이터 패칭이 Astro 프론트매터 대신 React 컴포넌트로 이동함. 해결: --- fence 내에서 데이터를 패칭하고, 서버 측에서 렌더링한 후 데이터를 props로 아일랜드에 전달.

타입 없는 프론트매터

증상: 빌드는 성공하지만 프로덕션에서 제목이 undefined로 표시됨. 진단: 콘텐츠 컬렉션 스키마가 없어 프론트매터 오타가 발견되지 않음. 해결: Zod 스키마와 함께 defineCollection을 사용하세요. 프론트매터 오류는 빌드를 실패시킵니다.

이미지에 public/과 src/assets/ 혼용

증상: 일부 이미지는 최적화되지만 다른 이미지는 원본 크기로 전송됨. 진단: public/은 그대로 제공되며, src/assets/만 Sharp를 통해 처리됨. 해결: 이미지를 src/assets/로 옮기고 <Image> 컴포넌트를 사용하세요. public/은 OG 이미지와 파비콘에만 사용.

SPA에 Astro 사용 시도

증상: 하이드레이션과의 끊임없는 싸움, 전체 페이지가 인터랙티브해질 때까지 아일랜드가 계속 증가. 진단: 잘못된 프레임워크 선택. Astro는 콘텐츠에 탁월하지만 SPA에는 Next/Remix가 필요함. 해결: 대부분의 페이지가 인터랙티브한 경우 Next/Remix를 사용하세요. 마케팅 + 문서에는 Astro를 사용.

client:only 남용

증상: 페이지 로드 시마다 레이아웃 시프트(CLS) 발생, 콘텐츠가 나타나기 전 "깜빡임" 현상. 진단: SSR을 건너뛰면 브라우저가 JS가 실행될 때까지 빈 자리 표시자를 보게 됨. 해결: 컴포넌트가 정말로 서버 측에서 렌더링될 수 없는 경우에만 client:only를 사용하세요. 최종 크기에 근접한 자리 표시자를 제공하세요.

품질 관문

  • 기본 클라이언트 지시어는 client:idle 또는 client:visible이고, client:load는 사용 사례별로 정당화됨.
  • 모든 콘텐츠는 defineCollection을 통해 타입이 지정된 스키마를 가짐.
  • 이미지는 src/assets/ 아래에 있고 <Image> 컴포넌트를 사용함.
  • 멀티-프레임워크 통합(@astrojs/react 등)은 실제로 존재하는 컴포넌트에만 추가됨.
  • 가장 느린 대표 페이지에서 LCP가 2초 미만.
  • 페이지별 첫 로드 JS 예산이 설정되었고, CI가 회귀를 감지하면 실패.
  • MDX는 정적 부분에 Astro 컴포넌트를 사용하고, 아일랜드는 인터랙티브가 필요한 곳에만 사용.
  • 뷰 트랜지션은 주요 탐색 경로에서 테스트됨.

사용하지 말아야 할 경우

  • 완전한 SPA — Next.js, Remix, TanStack Start가 더 적합합니다.
  • Astro 플러그인/통합 개발 — 별도 스킬 (전용 스킬 아직 없음).
  • Vite 측 빌드 튜닝 — Astro는 내부적으로 Vite를 사용합니다. 청크 크기, HMR, 플러그인 수명주기 문제는 → vite-build-optimizer 참고.
  • 무거운 클라이언트 상태 앱 (대시보드, 실시간 도구) — 아일랜드가 도움이 되기에는 JS가 너무 많습니다.
  • 네이티브 모바일 — Astro는 웹 전용입니다.

Individual skills in this repo

This repo contains 20 individual skills — each has its own dedicated page.

curiositech/windags-skills

Expert in 2000s-era music visualization (Milkdrop, AVS, Geiss) and modern WebGL implementations. Specializes in Butterchurn integration, Web Audio API AnalyserNode FFT data, GLSL shaders for audio-reactive visuals, and psychedelic generative art. Activate on "Milkdrop", "music visualization", "WebGL visualizer", "Butterchurn", "audio reactive", "FFT visualization", "spectrum analyzer". NOT for simple bar charts/waveforms (use basic canvas), video editing, or non-audio visuals.

curiositech/windags-skills

Expert legal research agent for finding and scraping expungement data state by state. Knows authoritative sources, URL patterns, Firecrawl configuration, and 2026 legal landscape.

curiositech/windags-skills

Expert in 3D computer vision labeling tools, workflows, and AI-assisted annotation for LiDAR, point clouds, and sensor fusion. Covers SAM4D/Point-SAM, human-in-the-loop architectures, and vertical-specific training strategies. Activate on '3D labeling', 'point cloud annotation', 'LiDAR labeling', 'SAM 3D', 'SAM4D', 'sensor fusion annotation', '3D bounding box', 'semantic segmentation point cloud'. NOT for 2D image labeling (use clip-aware-embeddings), general ML training (use ml-engineer), video annotation without 3D (use computer-vision-pipeline), or VLM prompt engineering (use prompt-engineer).

curiositech/windags-skills

Implement WCAG 2.2 AA/AAA compliance with automated testing, keyboard navigation, screen reader support, and focus management. Activate on: accessibility audit, WCAG compliance, keyboard navigation, screen reader, aria attributes, axe-core, focus trap. NOT for: design-level accessibility review (use design-accessibility-auditor), color contrast only (use css-in-js-architect).

curiositech/windags-skills

Time-blind friendly planning, executive function support, and daily structure for ADHD brains. Specializes in realistic time estimation, dopamine-aware task design, and building systems that actually work for neurodivergent minds.

curiositech/windags-skills

Designs digital experiences for ADHD brains using neuroscience research and UX principles. Expert in reducing cognitive load, time blindness solutions, dopamine-driven engagement, and compassionate design patterns. Activate on 'ADHD design', 'cognitive load', 'accessibility', 'neurodivergent UX', 'time blindness', 'dopamine-driven', 'executive function'. NOT for general accessibility (WCAG only), neurotypical UX design, or simple UI styling without ADHD context.

curiositech/windags-skills

>- Apply crisis decision-making research to agent routing, uncertainty triage, and coordination failure analysis in time-pressured systems. Use when diagnosing handoff failures, analytical paralysis, or expert judgment under incomplete information. NOT for routine coding, simple CRUD design, or static single-agent tasks with complete information.

curiositech/windags-skills

Extend and modify the admin dashboard, developer portal, and operations console. Use when adding new admin tabs, metrics, monitoring features, or internal tools. Activates for dashboard development, analytics, user management, and internal tooling.

curiositech/windags-skills

Conversation patterns and interaction protocols for multi-agent systems. Covers request/response, pub/sub, blackboard, delegation chains, debate, critique, consensus, fan-out/fan-in, supervisor-worker, and peer negotiation. Deep analysis of AutoGen conversation patterns, CrewAI delegation, LangGraph state passing, and FIPA-ACL performatives. Teaches how to design what agents say to each other and in what order. Activate on: "agent conversation", "agent protocol", "multi-agent debate", "agent delegation", "supervisor worker pattern", "agent voting", "consensus protocol", "fan-out fan-in", "agent negotiation", "blackboard pattern", "agent dialogue", "conversation topology", "agent handoff". NOT for: wire format or serialization (use agent-interchange-formats), orchestration infrastructure (use agentic-infrastructure-2026), single agent behavior (use agentic-patterns).

curiositech/windags-skills

Meta-agent for creating new custom agents, skills, and MCP integrations. Expert in agent design, MCP development, skill architecture, and rapid prototyping. Activate on 'create agent', 'new skill', 'MCP server', 'custom tool', 'agent design'. NOT for using existing agents (invoke them directly), general coding (use language-specific skills), or infrastructure setup (use deployment-engineer).

curiositech/windags-skills

AI-powered calendar management and agent-based scheduling coordination. Covers calendar APIs (Google Calendar, CalDAV/iCal), AI scheduling assistants (Reclaim, Clockwise, Motion, Cal.com), building custom calendar agents with MCP, multi-calendar merging, timezone management, focus block protection, meeting fatigue detection, and agent-to-agent meeting negotiation protocols. Activate on: "calendar agent", "AI scheduling", "calendar coordination", "meeting scheduling", "calendar API", "focus time protection", "calendar optimization", "Google Calendar MCP", "Reclaim", "Clockwise", "Motion", "Cal.com", "smart scheduling", "calendar-aware agent", "timezone scheduling", "agent negotiation meetings". NOT for: manual calendar UI component design (use form-validation-architect), project management scheduling or Gantt charts (use project-management-guru-adhd), general time-tracking or pomodoro apps (use adhd-daily-planner for time-awareness), building the agent itself from scratch (use agent-creator).

curiositech/windags-skills

Build and adopt production AI agent infrastructure in 2026. Covers framework selection (LangGraph, CrewAI, AutoGen, MCP), orchestration patterns, evaluation, observability, memory systems, and tool use. Also covers the SOCIAL dimension: how to sell agent infrastructure internally, change management, measuring ROI, building trust in autonomous systems, and scaling adoption across teams. Activate on: "agent infrastructure", "agent framework comparison", "which agent framework", "sell AI tools internally", "agent adoption", "agent observability", "agent evaluation", "MCP architecture", "agentic mesh", "enterprise AI agents", "AI change management", "agent ROI". NOT for: building specific agents (use ai-engineer), designing agent behavior patterns (use agentic-patterns), prompt tuning (use prompt-engineer).

curiositech/windags-skills

Fundamental patterns for effective agentic behavior. Teaches decomposition, tool orchestration, error recovery, context management, quality self-assessment, and knowing when to stop. Model-agnostic principles that make any agent more effective regardless of domain. Activate on: "how should I structure this agent", "agentic workflow", "agent patterns", "multi-step task", "tool orchestration", "/agentic-patterns", "decompose this", "agent best practices", "chain of actions", "when should the agent stop", "agent loop design". NOT for: creating agent infrastructure (use agent-creator), building DAGs (use windags-architect), specific tool implementation.

curiositech/windags-skills

Automated discovery and matching of agent skills for dynamic task routing and capability assessment

curiositech/windags-skills

Cryptographic security for agentic systems — zero-trust agent networking, signed message envelopes (JWS/JWE), capability-based security (ocaps), Merkle tree audit trails, WASM sandboxing, and formal verification. Covers CLI dev tool security, mTLS between agents, permission boundaries (least privilege for AI agents), and supply chain security for skills/plugins. Activate on: "agent security", "zero trust agents", "secure agent communication", "capability-based security", "ocap", "signed messages between agents", "agent audit trail", "sandbox agent execution", "agent permissions", "mTLS agents", "cryptographic verification", "agent supply chain", "OWASP agentic", "prove agent did X", "tamper-proof agent logs". NOT for: application-level SAST scanning (use security-auditor), network firewall rules (use infrastructure), SOC2/HIPAA compliance (organizational), or prompt injection defense (use prompt-engineer).

curiositech/windags-skills

Data structures and serialization formats for agent-to-agent communication. Covers message envelopes, structured output schemas, capability declarations, task handoff payloads, error/retry signaling, and context windows as data structures. Deep comparison of A2A protocol, MCP, OpenAI function calling, and LangChain message types. Teaches when to use rigid schemas vs free-form with validation, typed vs untyped, streaming vs batch. Activate on: "agent message format", "agent communication schema", "agent-to-agent protocol", "A2A protocol", "MCP message format", "structured output for agents", "agent interop", "interchange format", "agent serialization", "task handoff format", "capability declaration". NOT for: what agents say to each other (use agent-conversation-protocols), orchestration topology (use multi-agent-coordination), building agent infrastructure (use agentic-infrastructure-2026).

curiositech/windags-skills

Logic-based agent programming language implementing BDI architecture for practical autonomous agent development

curiositech/windags-skills

>- Design AgentSpeak(L)-style BDI agents with context-guarded plans, selection functions, and intention stacks. Use for interruptible autonomy, agent policy, and multi-agent orchestration in dynamic environments. NOT for simple rule engines, static planners, or centralized workflows.

curiositech/windags-skills

Foundational concurrent computation model where actors communicate exclusively through asynchronous message passing

curiositech/windags-skills

license: Apache-2.0 NOT for unrelated tasks outside this domain.

관련 스킬