ja_cli
v1.2.2
Published
A custom React project scaffolder CLI
Maintainers
Readme
ja_cli
ja_cli is a fast, developer-friendly CLI tool for scaffolding React projects with built-in best practices and a modern pastel gradient UI theme. It takes care of common project setup complexities, so you can focus on building features instead of boilerplate.
Features
- One-step scaffolding – Create React projects instantly with curated defaults.
- Pastel gradient UI – Stylish, modern design baked into templates.
- Route protection – Includes
ProtectedRouteandAdminRoutemiddleware for authentication-based routing. Only users with valid tokens can access protected pages. - Endpoint collections – Centralized API endpoints for simplified service calls.
- Axios setup – Preconfigured Axios instance with interceptors for consistent API requests.
- Notification helpers – Integrated with SweetAlert (swal) and React-Toastify for smooth user feedback and alerts.
- Socket client – Built-in
socket.client.jsfor seamless Socket.IO integration. - DataLake helper – Convenient storage utility for tokens, usernames, and other essential client-side data.
- Helpers library – Pre-built utilities (
axios.js,notification.js,endpoints.js,dataLake.js) to save development time.
Installation
Make sure you have Node.js installed.
Install ja_cli globally:
npm install -g ja_cliOr run it directly via npx:
npx ja_cliUsage
Start scaffolding your React project with:
ja_cliYou’ll be guided through interactive prompts to choose project name, template type, and additional options (such as including a sample login page).
Project Structure Highlights
A generated project comes with a production-ready folder setup:
src/
├── helpers/
│ ├── axios.js # Axios setup with interceptors
│ ├── dataLake.js # Utility for storing tokens, usernames, etc.
│ ├── endpoints.js # API endpoints collection
│ └── notification.js # SweetAlert + React-Toastify notifications
│
├── middleware/
│ ├── AdminRoute.jsx # Restricts access to admin-only pages
│ └── ProtectedRoute.jsx# Protects routes for authenticated users
│
├── plugins/
│ └── socket.client.js # Socket.IO client integration
│
├── routes/
│ ├── AdminRoutes.jsx # Admin-specific routes
│ └── AppRoutes.jsx # Main application routesThis structure ensures scalability, maintainability, and security from the start.
Example Workflow
$ ja_cli
? Enter project name: my-awesome-app
? Choose project template: React + TailwindCSS
? Include sample login page? Yes
Creating project...
Installing dependencies...
Project setup complete!
Next steps:
cd my-awesome-app
npm startContributing
Contributions are welcome.
Open issues or submit pull requests to suggest new features, improve existing utilities, or enhance CLI performance.
License
MIT License © 2025 Jay Tyagi
Contact
For questions or support, contact: [email protected]
