2.0.7 • Published 11 months ago
miryala v2.0.7
Miryala
miryala is a CLI tool that helps you scaffold a Node.js project with predefined folders and integrates Express and WebSocket. It saves time by automatically setting up controllers, middlewares, models, utils, and a ready-to-use server.js file.
Features
- Predefined folder structure:
controllers/middlewares/models/utils/routes/
- A ready-to-use
server.jswith:- Express setup
- WebSocket integration
- Included
app.jsfor API routes. - Automatically installs
express,ws, andnodemon.
Usage
Run the following command to scaffold a new project:
npx miryala- This command will:
- Create the predefined folder structure.
- Generate server.js and app.js with basic setup.
- Install express, ws, and nodemon automatically.
For Database Setup
- If you select MongoDB, ensure that the
MONGO_URIis specified in the.envfile. - If you select MySQL, ensure that the
MYSQL_DB,MYSQL_USER,MYSQL_PASSWORD, andMYSQL_HOSTare provided in the.envfile.
Starting the Project
- After the project is initialized with database setup, you can start the development server with:
npm run dev- This will start the server with nodemon, enabling hot-reloading during development.
License
- This project is licensed under the MIT License - see the LICENSE file for details.