Preact
Use when the user asks about Preact, Preact signals, preact/compat, Preact vs React, Preact SSR or cutting bundle size with a React-compatible library. Produces Preact components, signal-based state and compat aliasing. Not for React-specific architecture (use react-architecture).
Install
npx skills add j4flmao/agent-skills --skill preactgit clone --depth 1 https://github.com/j4flmao/agent-skills.git /tmp/agent-skills
mkdir -p ~/.claude/skills
cp -r /tmp/agent-skills/skills/frontend/preact ~/.claude/skills/preactPersonal skills live in ~/.claude/skills. Use .claude/skills in a project folder to share a skill with your team.
From the SKILL.md
# Preact
## Purpose
Build ultra-lightweight Preact applications using signals for reactive state, compat layer for React interop, and hooks for component logic — all under 3kB.
## Agent Protocol
### Trigger
Exact user phrases: "Preact setup", "Preact signal", "Preact hooks", "Preact project", "Preact vs React", "Preact SSR", "preact app".
### Input Context
Before activating, verify:
- package.json has preact dependency (or preact/compat).
- Whether the project uses Vite, WMR, or manual bundler.
- If React interop is needed (preact/compat).
### Output Artifact
No file output. Produces code snippets, config examples, and structural guidance as text.
### Response Format
Config:
```
// vite.config.ts
import { defineConfig } from 'vite'
import preact from '@preact/preset-vite'
export default defineConfig({ plugins: [preact()] })
```
Code: show component, signal, and hook definitions inline. No import statements.
No preamble. No postamble. No explanations. Compress output — why use many token when few do trick.
### Completion Criteria
- [ ] Entry point uses `render()` from preact (not ReactDOM).
- [ ] Stateful logic uses signals (@preact/signals) for local/global state.
- [ ] Hooks follow Preact compatibility (useEffect, useState, useMemo all work).
- [ ] JSX uses `h` pragma or compat layer.
- [ ] Bundle size is monitored — no heavy React-for-Preact swaps.
- [ ] SSR uses preact-render-to-string.
- [ ] Class components avoided (functional + hooks preferred).Details
- Skill name
preact- Repository
- j4flmao/agent-skills
- Path
skills/frontend/preact/SKILL.md- License
- MIT
- Repo updated
- 17 November 2026
FAQ
What does the Preact skill do?
Use when the user asks about Preact, Preact signals, preact/compat, Preact vs React, Preact SSR or cutting bundle size with a React-compatible library. Produces Preact components, signal-based state and compat aliasing. Not for React-specific architecture (use react-architecture).
How do I install the Preact skill?
skills CLI (Claude Code, Cursor, Codex and more): npx skills add j4flmao/agent-skills --skill preact. Skills go in ~/.claude/skills (personal) or .claude/skills (project), and Claude loads them automatically when a task matches the description.
Is Preact popular?
It lives in j4flmao/agent-skills, which has 45 GitHub stars and 6 forks.
Related skills
Agent Observability
45j4flmao/agent-skills
Use when the user asks about agent observability, tracing agent reasoning, debugging an agent loop, OpenTelemetry GenAI spans for LLM calls, LLM cost tracking per agent, agent audit logs or hallucination/eval monitoring in production. Produces instrumentation config, trace schema, dashboards, alerts and cost attribution. Not for generic service tracing without LLMs (use devops-opentelemetry).
AI Agent Architectures
45j4flmao/agent-skills
Use when the user asks to build an AI agent, design an agent that calls tools and keeps memory, write an agent system prompt or pick an agent framework (Claude Agent SDK, OpenAI Agents SDK, LangGraph). Produces an architecture brief covering loop, tools, memory, guardrails and evals, routing depth to child skills. Not for workflow patterns (use ai-agentic-workflows).
AI Agent Core Loop
45j4flmao/agent-skills
Use when the user asks about the agent loop, ReAct vs plan-and-solve, re-planning, Reflexion, an agent stuck in a loop, max iterations or termination conditions. Produces a loop spec or patch with state, success predicate, caps and no-progress detection. Not for overall agent design (use ai-agent-architectures) or tool schemas (use tool-calling-principles).
React Architecture
45j4flmao/agent-skills
Use when the user asks about React project structure, feature-based folders, a React component that re-renders too often, how to structure state and custom hooks, error boundaries or the React Compiler. Produces a React 19 app architecture with component and hook conventions. Not for Next.js App Router (use react-nextjs) or picking a state library (use frontend-state-management).
Nextjs Internals
45j4flmao/agent-skills
Use when the user asks why a Next.js route is dynamic, how the App Router renders and streams, the RSC payload, partial prerendering, Cache Components / 'use cache', the router cache or the request lifecycle. Produces a diagnosis of static vs dynamic rendering and stale data in Next.js 15/16. Not for everyday App Router features (use react-nextjs).
React Fiber Architecture
45j4flmao/agent-skills
Use when the user asks about React Fiber, reconciliation, render vs commit phase, lanes, concurrent rendering, time slicing, the React scheduler or why a component rendered twice. Produces an explanation of reconciler internals to debug render behaviour. Not for app architecture (use react-architecture) or React Three Fiber (use web3d-webgl).
Browse the most popular Claude skills, all frontend & design skills, or write your own with the skills generator.