easy-node-init v1.0.2-beta.4
Easy Node Initializer
Fast-track your Express.js and Mongoose-based API development with ease!
The Easy Node Initializer is a powerful tool designed to simplify the process of creating Express.js APIs integrated with MongoDB using Mongoose. Say goodbye to hours of manual configuration and file setup – with just a few simple commands, you can have your API up and running in seconds.
Getting Started
Install nodemon by running the following command in your project directory or modify it according to your ease:
npm i -g nodemonInstallation
Certainly! Here's the command for installing an npm package globally in Markdown format:
On Windows (run as Administrator):
npm install -g easy-node-initOn Linux/macOS (using sudo for superuser privileges):
sudo npm install -g easy-node-initTo set your secret key in an environment variable run the command:
export easynodeinti_jwtPrivateKey=<your-secret-key>To enable debugging:
export debug=app:*To start the server:
npm startTo run tests:
npm testMake sure to replace <your-secret-key> with your actual secret key when setting the easynodeinti_jwtPrivateKey environment variable.
Usage
Initialize Basic Express Setup
Use the following command to initialize a basic setup for an Express-based API:
eni setupInitialize Basic Express Setup
Initialize Basic Mongoose Setup
To set up essential files for Mongoose, execute the following command:
eni db-setupInitialize User Module
Create a user module with all the required functions, along with test files, using the following command:
eni authCreate a New Module
Generate a module with auto-generated controller, module, route, and integration test for it by running the following command, replacing <module-name> with your desired module name:
eni create-module <module-name>Create a New Controller
Create a new controller with auto-generated routes and integration tests by using the following command, replacing <controller-name> with your desired controller name:
eni create-controller <controller-name>License
This project is licensed under the MIT License - see the LICENSE file for details.
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago