December 2016
Intermediate to advanced
841 pages
17h
English
To test the application, the server and the static files have to be served from the same server. To do that, you can use the http-server package. That server can serve the static files and pass through (proxy) the requests to the API server. If MongoDB is not running yet, open a terminal window and run mongod --dbpath ./data. Open a terminal window in the root of the project and run the following to start the API server on localhost:8800:
gulp && node --harmony_destructuring dist/server
In a new terminal window, navigate to the static directory. Install http-server using the following command:
npm install http-server -g
Now you can start the server:
http-server -P http://localhost:8800
Open localhost:8080 in a browser and ...
Read now
Unlock full access