Simple starter Node.js Application with Typescript
-
Clone this repository
git clone https://github.com/OpesanyaAdebayo/Typescript-Node-Starter.git
-
Install dependencies
cd Typescript-Node-Starter
npm install
-
Create a
.env
file with the same variables as.env.sample
in this repository. Replace the contents with your ownSESSION_SECRET
andMLAB_URI
.Please note that
MLAB_URI
is the connection url for MongoDB. I used MLAB to manage my MongoDB instance but you can simply replace it with the url you use for your local MongoDB instance. -
Start your MongoDB server
mongod
-
Build the application
npm run build-ts
-
Start the application
npm run start
-
Endpoints can be accessed on
localhost:4000
.