Simple template repo for building quick and small web applications with NodeJS, typescript and express.
Uses handlebars as the tempate engine.
Prefect for rapid prototyping a web application, with simple frontend.
(Very lightweight, if you build something bigger use Vue.js or React, if
it is there to last Angular might be the right thing).
Has mocha as a testing framework.
Uses nodemon and the watch mode of the typescript compiler to recompile and
restart the application as soon as changes (to the .ts files) occur.
Might require typescript & tsc to be globally installed as well:
npm install -g typescript
Has some pre defined dependencies:
Express as the server framework for nodejs
Socket.IO to provide socket based communication
node-fetch to provide a simple http client (as development for request was stopped)
Install development and prod dependencies:
npm install
Run applcation in development mode (recompiles sources and restarts if typescript files change):
npm start
Run mocha tests:
npm test
Install production dependecies only (-> no devdependencies):
npm run prod:install
Build the typescript sources in production mode + set process.env.NODE_ENV="production"
(-> no devdependencies):
npm run prod:build
Run on production
npm run prod:start