DEV Community

Cover image for Vite Breeze (Automating React Project Structure Development With TailwindCSS)
BasitJawad
BasitJawad

Posted on

Vite Breeze (Automating React Project Structure Development With TailwindCSS)

Vite Breeze

A simple CLI tool to quickly generate a React project using Vite, React Router, and a pre-configured context folder. It also sets up Tailwind CSS, along with auto-created pages and components folders.

Note

Do not use ( npm i vite-breeze ) as it will not work because its a Cli-tool not a package.

πŸš€ Installation

Instead of installing globally, you can use npx to run the CLI directly:

npx vite-breeze
Enter fullscreen mode Exit fullscreen mode

Why npx?

Using npx vite-breeze is recommended because:

βœ… No Global Installation: Avoids version conflicts.
βœ… Always Up-to-Date: Ensures you're using the latest version.
βœ… Quick & Easy: Runs instantly without installation.

πŸ”§ Usage

Once you run the command, you'll be prompted to enter a project name:

πŸ“› Enter project name: my-react-app
Enter fullscreen mode Exit fullscreen mode

vite-breeze will then:

  1. Create a new directory with the specified name.
  2. Initialize a new Vite React project.
  3. Install dependencies including React Router, Axios, and Tailwind CSS.
  4. Configure Tailwind CSS automatically.
  5. Create the following folder structure in src/:
    • context/ - For React Context API files (AppContext.js included).
    • components/ - For reusable components.
    • pages/ - For page components.

βœ… After setup, follow these steps:

cd my-react-app
npm run dev
Enter fullscreen mode Exit fullscreen mode

πŸ“Œ Features

  • ⚑ Vite-Powered: Super-fast project setup.
  • 🎨 Tailwind CSS: Pre-configured for styling.
  • 🌍 React Router: Automatically installed.
  • πŸ›‘οΈ Axios: Automatically installed.
  • πŸ— Organized Structure: Creates a clean project layout.
  • πŸ”§ Context API Setup: Adds a ready-to-use AppContext.js.

🀝 Contributing

Contributions are welcome! Open an issue or submit a pull request on GitHub.

πŸ“œ License

πŸ‘¨β€πŸ’» Author

Basit Jawad

Top comments (0)