Skip to content

Latest commit

 

History

History
69 lines (53 loc) · 1.07 KB

readme.md

File metadata and controls

69 lines (53 loc) · 1.07 KB

TypeScript with Node & MongoDB

  • Backend - Express (written in TypeScript)
  • Frontend - Pug Templating Engine
  • Database - MongoDB + Mongoose (ORM)
  • FrontendDesign - Zurb Foundation
  • CSV Libs - JSON2CSV, CSV2JSON
  • File Upload - Multer --Awesome Library!

Run Docker Container

$ cd nodeTSMongo
$ docker pull burningraven06/node-ts-mongo
$ docker-compose up

Run App Locally

  • Create DB Config
$ cd nodeTSMongo
$ touch src/config/keys.ts
  • Update src/config/keys.ts
const AppKeys = {
  mongoDBURL : <YOUR_MONGODB_URL>,
  mongoDBDockerURL : ""
}

export default AppKeys
  • Update src/hostApp.ts
$ cd nodeTsMongo/src/   #Open hostApp.ts

# Change Line 19
public mongoURL : string = AppKeys.mongoDBDockerURL

# to 
public mongoURL : string = AppKeys.mongoDBURL
  • Install Package Dependencies
$ cd nodeTSMongo
$ yarn install

#Or, with npm
$ npm install
  • Run App in DEV Mode
$ cd nodeTSMongo
$ yarn watch-ts
$ yarn watch-js
  • Run App in PROD Mode
$ cd nodeTSMongo
$ yarn run production