/quickstart-react

React Package Solution

Primary LanguageJavaScriptMIT LicenseMIT

⚑ quickstart-react (React Package Solution)

πŸš€ quickstart-react is an open-source CLI tool that lets you instantly create a Vite + React app with your choice of CSS framework, optional packages, and pre-configured project structure β€” all in one command.

✨ Features

  • Interactive Setup β€” prompts you for project name, CSS framework, and optional packages
  • CSS Framework Support β€” Tailwind CSS, Bootstrap, or MUI (Material UI)
  • Optional Packages β€” easily add Axios, React Icons, React Hook Form, Yup, Formik, and Moment.js
  • Automatic Folder Structure β€” creates components, pages, hooks, store, utils, assets folders
  • Boilerplate Ready β€” replaces default Vite boilerplate with a clean welcome page
  • Axios Setup β€” pre-configured Axios instance if selected
  • CSS Integration β€” automatically configures your chosen CSS framework with Vite

πŸ“¦ Installation

You don’t need to install it globally β€” run it instantly with npx:

npx quickstart-react

πŸ›  Usage

When you run npx quickstart-react, you will be prompted to:

  1. Enter Project Name β€” e.g., my-app
  2. Choose CSS Framework β€” Tailwind, Bootstrap, or MUI
  3. Select Optional Packages β€” choose from a list of commonly used React libraries

Example run:

npx quickstart-react

Example Walkthrough

? Enter project name: my-portfolio
? Choose a CSS framework: Tailwind
? Select optional packages: Axios, React Icons

This will:

  • Create a new Vite + React project in my-portfolio/
  • Install Tailwind CSS and configure it with Vite
  • Install Axios and React Icons
  • Create standard project folders
  • Add a clean welcome screen
  • Set up an Axios instance at src/utils/axiosInstance.js

πŸ“‚ Folder Structure

After running, your project will look like this:

my-app/
β”œβ”€β”€ src/
β”‚   β”œβ”€β”€ components/
β”‚   β”œβ”€β”€ pages/
β”‚   β”œβ”€β”€ hooks/
β”‚   β”œβ”€β”€ store/
β”‚   β”œβ”€β”€ utils/
β”‚   β”‚   └── axiosInstance.js (if Axios selected)
β”‚   β”œβ”€β”€ assets/
β”‚   β”œβ”€β”€ App.jsx
β”‚   β”œβ”€β”€ index.css
β”‚   └── main.jsx
β”œβ”€β”€ vite.config.js
β”œβ”€β”€ package.json
└── README.md

⚑ CSS Framework Integration

Tailwind CSS

  • Installs tailwindcss & @tailwindcss/vite
  • Updates vite.config.js to use Tailwind plugin
  • Sets up index.css with Tailwind directives
  • Removes unused default CSS files

Bootstrap

  • Installs bootstrap
  • Imports Bootstrap CSS in main.jsx
  • Removes unused default CSS files

MUI (Material UI)

  • Installs @mui/material, @emotion/react, @emotion/styled
  • Removes unused default CSS files

🧩 Optional Packages

You can add these during setup:

  • Axios β€” with a ready-to-use axiosInstance.js
  • React Icons β€” icon library
  • React Hook Form β€” form management
  • Yup β€” schema validation
  • Formik β€” form management
  • Moment.js β€” date/time utilities

πŸš€ Quick Start

npx quickstart-react my-dashboard

Select Tailwind, Bootstrap, or MUI, add any packages, and start coding immediately

πŸ‘ Contributing

We welcome contributions! Follow these steps:

  1. Fork the repository
  2. Create a new branch: git checkout -b feature-name
  3. Commit your changes: git commit -m "Added new feature"
  4. Push to your branch: git push origin feature-name
  5. Open a Pull Request

Before submitting, please ensure:

  • Your code follows project style guidelines
  • You have tested your changes locally

Happy Hacking πŸ±β€πŸ