Skip to content

mortenmathiasen/MEAN-socket-template

Repository files navigation

MEAN-socket-template

This template project for building MEAN applications is based on Mongoose, Express, Angular, NodeJS and Socket IO. The template uses the Angular CLI build system for compilation and deployment of the frontend application into the NodeJS server.

Below instructions explain how to get started using this template, either with or without live updates as source files changes.

Online test

You can try the template application at (https://mean-socket-template.herokuapp.com/). The online example is deployed to free services at Heroku (https://www.heroku.com) and mLab (https://mlab.com).

Install prerequisities

  1. Install NodeJS (https://nodejs.org)
  2. Install Angular CLI (https://cli.angular.io)
  3. Install Mongo (https://www.mongodb.com)

Get the software

  1. Clone this project
  2. Open root folder in terminal
  3. Execute: npm run prepare
  4. Execute: npm install

Start database

  1. Start mongo daemon, learn how on (https://docs.mongodb.com/manual/administration/install-community/)

Run

  1. Execute: npm run build
  2. Execute: npm run start

Run with live updates

  1. Execute: npm run live_build
  2. Execute: npm run live_start

Access running solution

  1. Open your localhost in browser (http://127.0.0.1:3000/)

Contribution

Contribution is very welcome. Please, follow code of conduct.

License

License: MIT