React
React component-based UI with hooks, context, and state management. Use for .jsx/.tsx files.From its SKILL.md
npx -y skills add G1Joshi/Agent-Skills --skill reactAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
One thing to look at
- 12 stars12 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
SKILL.md
2.6 KB, 629 tokens by cl100k_base, as published. Nobody here has run it
React
React is the standard library for building user interfaces. React 19 (2025) introduces a new era with the React Compiler, Server Components, and Actions.
When to Use
- Single Page Apps (SPA): Rich, interactive dashboards.
- Complex UI: Applications with many moving parts and state.
- Ecosystem: When you need the largest library of 3rd party components.
Quick Start (React 19)
import { use, Suspense } from "react";
// New: 'use' hook for promises
function Comments({ commentsPromise }) {
const comments = use(commentsPromise);
return comments.map((c) => <p key={c.id}>{c.text}</p>);
}
export default function Page({ id }) {
const commentsPromise = fetchComments(id);
return (
<Suspense fallback={<p>Loading...</p>}>
<Comments commentsPromise={commentsPromise} />
</Suspense>
);
}
Core Concepts
React Compiler
React 19 introduces an auto-memoizing compiler. You no longer need useMemo or useCallback manually in 99% of cases. The compiler treats code as "memoized by default".
Server Components (RSC)
Components that run only on the server. They don't send JS to the client.
'use server': Marks a function as a Server Action (callable from client).'use client': Marks a component as interactive (hydrated on client).
Actions and useActionState
Native support for async form submission.
function Form() {
const [error, submitAction, isPending] = useActionState(
async (prev, formData) => {
const error = await updateProfile(formData);
if (error) return error;
return null;
},
null,
);
return (
<form action={submitAction}>
<input name="name" />
<button disabled={isPending}>Save</button>
{error && <p>{error}</p>}
</form>
);
}
Best Practices (2025)
Do:
- Trust the Compiler: Stop writing
useMemo/useCallbackunless you are building a library or strictly optimizing. - Use Server Actions: Replace manual
fetch('/api/...')with robust Server Actions for data mutations. - Use
refas a prop: In React 19,refis a plain prop. No moreforwardRef.
Don't:
- Don't overuse
useEffect: Effects are for synchronization with external systems, not for data fetching or derived state. - Don't spread props blindly: Pass explicit props to make components easier to debug.
References
What ships with it
Read from the repository
Just SKILL.md. No reference files, no scripts.