You should follow this workflow to build your easily maintainable, secure API with ExpressJS and MongoDB.
Check source code you will get the idea. This workflow is also followed by me. Create an issue to give me suggestions. Don't forget to read the docs (Perfectly autogenerated with swagger-autogen), it is available on http://localhost:3000/docs
.
- Rename
env
to.env
& fill everything - Install dependencies by running
npm i
npm run dev
to run this as development
- Create a fulltext search index
db.posts.createIndex({ title: "text", content: "text" })
- This Project is MIT Licensed
- Copyright 2021 by Tuhin Kanti Pal