express app using mongodb+mongoose and written in typescript
this app is mostly an exercise to demonstrate different things i'm learning in 2019 (e.g. typescript, mongo), and not for production anywhere. please feel free to reach out if you find anything interesting.
install:
yarn
start database:
mongod --dbpath="./data"
for hot restart with nodemon and ts-node:
yarn dev
to compile and run:
yarn start
to create an entity:
curl -X "POST" http://localhost:8081/api/entities -H "Content-Type: application/json" -d '{\"name\":\"Margaret\"}'
to get entities:
curl http://localhost:8081/api/entities