Skip to content

sri443/react-clean-start

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

react-clean-start

Minimal React project initializer. Creates a fresh Vite (or CRA) project and removes default boilerplate such as demo assets, test files, and reportWebVitals, leaving a minimal starter template.

Usage

npx react-clean-start <project-name> [options]

Options

Flag Description
--cra Use Create React App instead of Vite (default: Vite)
--ts Use TypeScript template
--folders Add a standard src/ folder structure
--tailwind Set up Tailwind CSS (Vite only)

Note: --tailwind is only supported with Vite. Combining it with --cra prints an error and exits without creating a project.

Examples

# Vite + JavaScript
npx react-clean-start my-app

# Vite + TypeScript
npx react-clean-start my-app --ts

# Vite + Tailwind CSS
npx react-clean-start my-app --tailwind

# Vite + TypeScript + Tailwind CSS + folders
npx react-clean-start my-app --ts --tailwind --folders

# CRA + TypeScript + folders
npx react-clean-start my-app --cra --ts --folders

What it does

  • Clean App component (no demo UI)
  • Clean entry file (main.jsx / index.js) without dead imports
  • Removes demo assets and unnecessary starter files (logo.svg, App.css, tests, reportWebVitals, etc)
  • Optionally creates a src/ folder structure (see below)
  • Optionally sets up Tailwind CSS v4 (Vite projects only, via @tailwindcss/vite)

Generated structure

With --folders, this gets added under src/:

src/
├── components/
├── pages/
├── hooks/
├── services/
├── utils/
├── assets/
└── styles/

Requirements

  • Node.js >= 18
  • Internet connection (runs create-vite or create-react-app under the hood)

Troubleshooting

If npx react-clean-start uses an older cached version, run:

npx react-clean-start@latest my-app

This forces npx to use the latest published version.

License

MIT

About

Minimal React project initializer. Creates a fresh Vite (or CRA) project and removes default boilerplate such as demo assets, test files, and reportWebVitals, leaving a minimal starter template.

Resources

Stars

1 star

Watchers

0 watching

Forks

Packages

 
 
 

Contributors