The current project structure is as follows:
/
├── .github/ scripts and configs for github templating and workflows
├── .nyc_output/ istanbul coverage output (generated on running npm run cover:test)
├── build/ JS build of the project (generated on running npm run build)
├── coverage/ istanbul coverage report (generated on running npm run cover:report)
├── docs/ code documentation by typedoc (generated on running npm run docs)
├── node_modules/ directory that stores generated code of every node module
├── scripts/ deploy scripts
├── src/
├── config/ configurations for modules like db, swagger doc, etc go here
├── controllers/ controller functions for every route
├── dtos/ data transfer object definitions for cross function object passing
├── middlewares/ middlewares for various routes go here
├── models/ database schema / models go here
├── repositories/ database calls go here
├── routes/ routes or endpoint definitions go here, routes make calls to controllers
├── services/ main business logic implementation
├── tests/ directory for endpoint testing
├── fixtures/ for pre-defining data and environments for tests
├── integration/ for integration tests using BDD methodology
├── utils/ utility functions used for testing go here
├── views/ the frontend of the project in EJS, CSS and js
├── utils/ utility or helper functions go here
├── app.ts entry point to our express app
├── .env.production environment variables used in the project for prod
├── .env.development environment variables used in the project for dev
├── .gitignore stores files and directories to be ignored in commits
├── .prettierrc configuration for prettier to help maintain a common code formatting
├── docker-compose.prod.yml config file to define containers (for prod)
├── docker-compose.yml config file to define containers
├── Dockerfile Docker commands to create the docker image go here
├── package.json metadata of the project
├── package-lock.json stores version of every package used in the project
├── readme.md details and instructions about the project go here
├── sonar-project.properties configs for sonarqube, used for code quality analysis
└── tsconfig.json typescript configs