/node-koa-server

A sample node.js web app: nunjucks, koa.js, mongo, mysql, request.js, angular. Chinese please see the link for how to construct the koa node.js project with nunjucks

Primary LanguageJavaScript

node-koa-server

Demo of node.js server, code with Koa.js, nunjucks, request.js, mongo, mysql, angular.

The project still in developing, any problem please issue here.

Environment:

IDE: WebStorm 2017.1.2
Node.js: v7.6.0 +

Suggestion tool n for multiple node version control.

Usage:

Clone codes from github:

$ git clone https://github.com/gaoshanyu/node-koa-server.git
$ cd node-koa-server
$ npm install

1. Start via terminal:

$ node app.js

2. Start via WebStorm:

  • Install the WebStorm for you pc;
  • Open WebStorm application;
  • Choose: File/Open, find the project where you download from github and open it;
  • Right click the app.js and choose Run option;
  • When you see "Starting server at: http://localhost:3000" in the console area, copy the address "http://localhost:3000" and paste to browser.

QA:

  1. Why there is too many red wavy lines for my codes in WebStorm?

Please got to "Preferences/Languages & Frameworks/Javascript", then select ECMAScript6 as your JavaScript language version.