$ npm install -g create-express-api-mvc
$ express-api myapp
create : myapp
create : myapp/package.json
create : myapp/app.js
create : myapp/controllers/
create : myapp/controllers/home.js
create : myapp/config/
create : myapp/config/main.js
create : myapp/models/
create : myapp/models/main.js
create : myapp/
create : myapp/app.js
create : myapp/
create : myapp/router.js
$ cd myapp && npm install
- Open your config/main.js , Please configure your mongo db.(if you don't there will be error)
$ express-api myapp
myapp
|
|
|____controller
| |____home.js
|
|
|____config
| |
| |____main.js
|
|____node_modules
|
|
|____models
| |__main.js
|
|
|
|
|____router.js
|
|
|
|_____app.js
|
|
|
|_____package.json
Inspired by https://github.com/expressjs/generator
create-express-api-mvc is under MIT license - http://www.opensource.org/licenses/mit-license.php