react-app-scaffolder
Skill3 starsChanged 3 months agoMITView on GitHub
Scaffolds a production-ready React + TypeScript application skeleton with Vite, a router, strict TypeScript, Vitest + React Testing Library, ESLint (hooks + jsx-a11y), Prettier, environment handling, an error boundary, and a feature-folder layout. React analog of an app/project scaffolder. Use when starting a new React app, bootstrapping a Vite + React + TypeScript project, setting up the testing/lint toolchain, or establishing the base folder structure and app shell.
- Reads credentials
- Installs packages
In this repository86 other files it gives its agents.
- AGENTS.mdAGENTS.md
- project-templates/AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- project-templates/CLAUDE.mdCLAUDE.md
- alembic-migration-managerSkill
- architecture-journalSkill
- architecture-reviewSkill
- automated-code-reviewSkill
- axum-scaffolderSkill
- capture-consolidateSkill
- cargo-package-scaffoldSkill
- code-review-coachSkill
- confluence-guide-writerSkill
- dependency-mapperSkill
- doc-syncSkill
- dotnet-architecture-checklistSkill
- dotnet-controller-api-scaffolderSkill
- dotnet-security-reviewSkill
- dotnet-vertical-sliceSkill
- ef-migration-managerSkill
- email-captureSkill
- environment-healthSkill
- evaluate-testsSkill
- fastapi-scaffolderSkill
- fitness-functionsSkill
- jira-comment-writerSkill
- legacy-migration-analyzerSkill
- minimal-api-scaffolderSkill
- nuget-package-scaffoldSkill
- oss-vettingSkill
- pattern-tradeoff-analyzerSkill
- php-api-scaffolderSkill
- php-architecture-checklistSkill
- php-feature-sliceSkill
- php-migration-managerSkill
- php-package-scaffoldSkill
- php-security-reviewSkill
- pr-feedback-writerSkill
- pypi-package-scaffoldSkill
- python-architecture-checklistSkill
- python-feature-sliceSkill
- python-modernization-analyzerSkill
- python-security-reviewSkill
- qraspi-architectureSkill
- qraspi-graduateSkill
- qraspi-implementSkill
- qraspi-planSkill
- qraspi-questionsSkill
- qraspi-researchSkill
- qraspi-skeletonSkill
- qrspi-implementSkill
- qrspi-planSkill
- qrspi-questionsSkill
- qrspi-researchSkill
- qrspi-specSkill
- react-architecture-checklistSkill
- react-component-scaffolderSkill
- react-feature-sliceSkill
- react-modernization-analyzerSkill
- react-security-reviewSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
1 rule. About 0 are common, 0 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈0
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 63
If package.json already exists, do not clobber it — scaffold missing pieces only, and confirm first.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
React App Scaffolder
"Make the right thing the easy thing. A project's defaults become its culture." -- Adapted from engineering practice
"Strict from day one is cheaper than strict retrofitted." -- Adapted from TypeScript adoption experience
Core Philosophy
The first commit sets the project's defaults, and defaults are sticky: a project that starts without
strict TypeScript, without a test runner, or without lint rarely gains them later without pain. This
skill stands up the skeleton with the non-negotiables already on — strict types, Vitest, ESLint with the
hooks and a11y plugins, a router, an error boundary, and a feature-folder layout — so the first real
feature drops into a structured, tested, type-safe project.
Vite is the default bundler (fast, modern, ESM-native). Create React App is deprecated and is never the
target for a new project — if an existing CRA app is in play, route to react-modernization-analyzer.
Grounding note: the KB has no React corpus. Use
collection="javascript"for TS/tooling and cite react.dev / Vite + Vitest docs as the authority. Never invent areactcollection.
Non-Negotiable Constraints:
- Vite + TypeScript
strict—strict: trueintsconfigfrom the first commit - Test runner wired — Vitest + React Testing Library with a
testscript and a passing smoke test - Lint + format wired — ESLint (react-hooks + jsx-a11y) and Prettier with scripts
- Router from the start — a router with a typed route table and a not-found route
- Error boundary at the shell — a top-level error boundary so one throw does not blank the app
- Env via Vite convention — only
VITE_*exposed to the client; secrets stay server-side - React Compiler wired — stable since React Compiler 1.0 (Oct 2025); by 2026 it is the default assumption for a new React project, not an opt-in experiment
What this skill is NOT:
- It is NOT a feature generator — use
react-feature-slice/react-component-scaffolderfor that - It is NOT a deployment/CI guide — it covers the application skeleton; CI is a follow-up
- It is NOT a styling-framework decision — leave styling choice to the team
The 10 domain principles, knowledge-base lookups, discipline rules, the anti-pattern catalog, and
error-recovery procedures live in references/conventions.md.
Workflow
Phase 1: DETECT
node -v && npm -v
ls package.json 2>/dev/null && echo "existing project — confirm before overwriting"
# If a Create React App project exists, STOP and route to react-modernization-analyzer.
grep -l "react-scripts" package.json 2>/dev/null && echo "CRA detected → modernization, not fresh scaffold"If package.json already exists, do not clobber it — scaffold missing pieces only, and confirm first.
Phase 2: CREATE
npm create vite@latest <app-name> -- --template react-ts
cd <app-name>
npm install
npm install -D vitest @testing-library/react @testing-library/user-event jsdom \
eslint-plugin-react-hooks eslint-plugin-jsx-a11y prettier babel-plugin-react-compiler
npm install react-router-domPhase 3: CONFIGURE
Apply the structure and config. See references/project-structure.md for full file contents.
src/
app/
App.tsx # shell: providers + router + error boundary
routes.tsx # typed route table (home, layout, 404)
ErrorBoundary.tsx # top-level error boundary
features/ # feature slices land here (react-feature-slice)
shared/ # cross-cutting UI + utilities (http client, etc.)
test/setup.ts # RTL + jest-dom setup
main.tsx # createRoot
vite-env.d.ts # typed VITE_* env
eslint.config.js
vitest.config.ts
.env.example
.prettierrc
tsconfig.json # strictSee references/toolchain-config.md for tsconfig, eslint.config.js (incl. compiler lint rules),
vite.config.ts (React Compiler babel plugin), vitest.config.ts, and scripts.
Phase 4: VERIFY
npm run typecheck # tsc --noEmit, strict
npm run lint # eslint clean
npm run test # smoke test green
npm run build # production build succeeds
npm run dev # dev server bootsState Block
<react-app-scaffold-state>
phase: DETECT | CREATE | CONFIGURE | VERIFY | COMPLETE
app_name: [name]
existing_project: true | false
cra_detected: true | false
strict_ts: true | false
router_configured: true | false
test_harness_configured: true | false
lint_configured: true | false
error_boundary_added: true | false
compiler_enabled: true | false
last_action: [description]
next_action: [description]
</react-app-scaffold-state>Output Template
Emit the scaffold checklist (Toolchain · App Shell · Scripts · Verification) as the progress report.
Full markdown checklist: references/conventions.md → "Scaffold Checklist (Output Template)".
Integration with Other Skills
| Skill | Relationship |
react-feature-slice | The first thing to use after the skeleton — adds feature slices into src/features/. |
react-component-scaffolder | Generates individual components/routes within the scaffolded app. |
react-modernization-analyzer | For an existing CRA / legacy app, assess and plan the move to this Vite skeleton instead of scaffolding fresh. |
react-security-review | Run once features land to verify CSP, env exposure, and dependency posture. |
tdd-loop | Drive the first features test-first on top of the scaffolded Vitest harness. |
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

