1.0.20 • Published 5 years ago

@vixnguyen/naf v1.0.20

Weekly downloads
21
License
ISC
Repository
github
Last release
5 years ago

Naf CLI

The CLI helps to create a Node API application with MongoDB, Fastify and Swagger.

Setting up

1. Installation

Firstly, install it with:

npm install -g @vixnguyen/naf

Now you can run naf by simply doing:

naf

2. Project Initial

The Naf CLI makes it easy to create an application that already works, right out of the box. It already follows our best practices.

naf init

Development

1. Prerequisites

  • NodeJS
  • MongoDB

2. Code generating

After a new project initialized, at the root folder of your project, you can generate controllers, routes, schemas and models with a simple command in the table below:

ScaffoldUsage
Modelnaf model
Controller, Route, Schemanaf controller

Note that the generating script only support when you run it at the root folder of your project.

3. Run

Install dependencies

npm install

Serve with hot reload at localhost:2101

npm start

1.0.20

5 years ago

1.0.19

5 years ago

1.0.18

5 years ago

1.0.17

5 years ago

1.0.16

5 years ago

1.0.15

5 years ago

1.0.14

5 years ago

1.0.13

5 years ago

1.0.12

5 years ago

1.0.11

5 years ago

1.0.10

5 years ago

1.0.9

5 years ago

1.0.8

5 years ago

1.0.7

5 years ago

1.0.6

5 years ago

1.0.5

5 years ago

1.0.4

5 years ago

1.0.3

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago