Agent skill
react-new-project
Create a new React project using Vite, TypeScript, and Feature-based architecture.
Install this agent skill to your Project
npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/other/other/react-new-project
SKILL.md
React + Vite + TypeScript Project Generator
This skill guides the creation of a modern React application using Vite and organizes it into a scalable feature-based architecture.
Prerequisite
- Node.js and npm installed
Directory Structure (Feature-Based)
The goal is to move away from purely technical folders (components, hooks) to domain-oriented folders (features).
project-name/
├── src/
│ ├── app/ # Global app setup (providers, router, store)
│ ├── features/ # Feature-based modules
│ │ ├── auth/ # Example feature
│ │ │ ├── components/
│ │ │ ├── hooks/
│ │ │ └── types/
│ │ └── dashboard/
│ ├── shared/ # Shared utilities and UI components
│ │ ├── ui/ # Generic UI components (Buttons, Inputs)
│ │ └── utils/ # Helper functions
│ ├── App.tsx
│ └── main.tsx
└── ... config files
Step-by-Step Instructions
1. Initialize Vite Project
# Create project using the React-TypeScript template
npm create vite@latest __PROJECT_NAME__ -- --template react-ts
cd __PROJECT_NAME__
2. Install Dependencies
npm install
3. Setup Folder Structure
Remove default boilerplate and create the architecture:
# Clean up default assets if desired (optional)
# rm src/assets/react.svg
# Create core directories
mkdir -p src/app
mkdir -p src/features
mkdir -p src/shared/ui
mkdir -p src/shared/utils
mkdir -p src/shared/hooks
4. Basic Configuration
- Ensure
vite.config.tsis set up (defaults are usually fine). - Recommend setting up path aliases (e.g.,
@/pointing tosrc/) intsconfig.jsonandvite.config.tsif the user agrees, but start with standard relative paths for simplicity unless requested.
Verification
Run the dev server to ensure it starts:
npm run dev
Parent Hub
- _frontend-mastery
Part of Workflow
This skill is utilized in the following sequential workflows:
- _workflow-feature-lifecycle
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
Didn't find tool you were looking for?