omni-express

1.0.4 • Public • Published

omni-express

NPM Version NPM Downloads NPM Downloads Total Maintenance

Known Vulnerabilities GitHub issues GitHub forks GitHub stars

Installation

This is a Node.js module available through the npm registry.

Before installing, download and install Node.js. Node.js 8.0.0 or higher is required.

Using npm

$ npm install -g omni-express

Using yarn

$ yarn global add omni-express

Create the project:

Using npm

$ omni-express new myProject

Using yarn

$ omni-express new myProject --yarn

New project flags

--code - To open vscode after creation
--no-git - To disable git init

Create new component:

$ omni-express generate:component myNewComponent
or
$ omni-express g:c myNewComponent

Create new middleware:

$ omni-express generate:middleware myNewMiddleware --global /local
or
$ omni-express g:m myNewMiddleware --global/local
  • global to set app.use(myNewMiddleware)
  • local to use on one or more route(s)

Folder structure

|-- root folder
|  +--● bin
|  |  |--- server.js
|  |
|  +--● src
|  |  +---● components
|  |  |   +--● default
|  |  |   |  +--● controller
|  |  |   |     |-- index.js
|  |  |   |-- router.js
|  |  |
|  |  +---● middleware
|  |      |-- setHeaders.js
|  |
|  +--- app.js
|  |
|  |--- routes.js
|
|-- index.js

License

npm

Package Sidebar

Install

npm i omni-express

Weekly Downloads

1

Version

1.0.4

License

MIT

Unpacked Size

18.7 kB

Total Files

26

Last publish

Collaborators

  • andreoneti