Scaffold tool for m10-based projects
Work in progress
npm i -g m10-cli
- Create a new boilerplate project
- Generate CRUD resources for existing project
- Add route/validation to existing project
m10-cli new folder-name-here
Will create a new boilerplate with the following folders/files (you don't need to follow this pattern, you can use any files and folder in your configuration file):
-
app.jsExpress and m10 setup -
config.jsonBlank configuration -
schema/Empty folder for validation files -
handler/Empty folder for handler files -
middleware/Empty folder for middleware files
In the root of your m10 project run:
m10-cli add crud
Follow the prompts and will generate a complete CRUD handlers/validations automatically with MongoDB support.
In the root of your m10 project run:
m10-cli add route
Follow the prompts and will generate a new route and validation based on your inputs.