Skip to content

An API made using Typescript, NodeJs,Mongodb and all good programming practices, such as Clean Architecture, SOLID principles, TDD and Design Patterns. πŸ–‹

License

Notifications You must be signed in to change notification settings

gabriellopes00/clean-typescript-api

Repository files navigation

Clean Typescript API typescript

version badge Build Status Coverage Status stars badge license badge

Application hosted at heroku.
An API mande with

typescript mongodb nodejs docker eslint jest heroku travis-ci swagger

About this project βš™

This is an API made in NodeJs, Typescript, TDD, Clean Architecture e SOLID Course, course led by Rodrigo Mango. In this course we develop an API using Node.JS, Typescript, Mongodb and all good programming practices, such as Clean Architecture, SOLID principles, TDD and Design Patterns. πŸ–‹ Although i did this project following the course, i made my own changes and improvements.

Building πŸ”§

You'll need Node.js, Mongodb and i recommend that you have installed the Yarn on your computer. After, you can run the scripts below...

Cloning Repository
git clone https://github.com/gabriellopes00/clean-typescript-api.git &&
cd clean-typescript-api &&
yarn install || npm install
Running API (development environment)
yarn dev || npm run dev
Generating Build and running build
yarn build && yarn start || npm run build && npm run start
Docker 🐳

You will need to have docker and docker-compose installed on your computer to run the commands below. Running this commands the containers will be pulled node:14 image and mongo:4 image, and the containers will be created on top of this images.

yarn up || npm run up
yarn down || npm run down
Tests (jest) πŸ§ͺ
  • All ❯ yarn test
  • Coverage ❯ yarn test:ci
  • Watch ❯ yarn test:watch
  • Unit(.spec) ❯ yarn test:unit
  • Integration(.test) ❯ yarn test:integration
  • Staged ❯ yarn test:staged
  • Verbose(view logs) ❯ yarn test:verbose
Lint (eslint) 🎭
  • Lint(fix) ❯ yarn lint
Debug 🐞
  • Debug ❯ yarn debug
Statistics of the types of commits πŸ“ŠπŸ“ˆ

Following the standard of the Conventional Commits.

  • feature commits(amount) ❯ git shortlog -s --grep feat
  • test commits(amount) ❯ git shortlog -s --grep test
  • refactor commits(amount) ❯ git shortlog -s --grep refactor
  • chore commits(amount) ❯ git shortlog -s --grep chore
  • docs commits(amount) ❯ git shortlog -s --grep docs
  • build commits(amount) ❯ git shortlog -s --grep build

Contact πŸ“±

Github Badge Linkedin Badge Twitter Badge Gmail Badge Facebook Badge Instagram Badge StackOverflow Badge