Skip to content

RESTful API in Node.js using TypeScript, Clean Architecture, and TDD. Focused on best development practices to create scalable and easy-to-maintain applications.

License

Notifications You must be signed in to change notification settings

joaogbrieldev/clean-node-api

Repository files navigation

Coverage Status Known Vulnerabilities js-standard-style GPLv3 License Open Source

Clean Node API

APIs built

  1. Register
  2. Login
  3. Create poll
  4. List poll
  5. Answer the poll
  6. Poll result

Principles

  • Single Responsibility Principle (SRP)
  • Open Closed Principle (OCP)
  • Liskov Substitution Principle (LSP)
  • Interface Segregation Principle (ISP)
  • Dependency Inversion Principle (DIP)
  • Separation of Concerns (SOC)
  • Don't Repeat Yourself (DRY)
  • You Aren't Gonna Need It (YAGNI)
  • Keep It Simple, Silly (KISS)
  • Composition Over Inheritance
  • Small Commits

Design Patterns

  • Factory
  • Adapter
  • Composite
  • Decorator
  • Proxy
  • Dependency Injection
  • Abstract Server
  • Composition Root
  • Builder
  • Singleton

Methodologies and Designs

  • TDD
  • Clean Architecture
  • DDD
  • Conventional Commits
  • GitFlow
  • Modular Design
  • Dependency Diagrams
  • Use Cases
  • Continuous Integration
  • Continuous Delivery
  • Continuous Deployment

Libraries and Tools

  • NPM
  • Typescript
  • Git
  • Docker
  • Jest
  • MongoDb
  • Travis CI
  • Swagger
  • Bcrypt
  • JsonWebToken
  • Faker
  • Coveralls
  • Validator
  • Express
  • Apollo Server Express
  • Graphql
  • Graphql ISO Date
  • Graphql Scalars
  • Graphql Tools
  • Supertest
  • Husky
  • Lint Staged
  • Eslint
  • Standard Javascript Style
  • Sucrase
  • Nodemon
  • Rimraf
  • In-Memory MongoDb Server
  • MockDate
  • Module-Alias
  • Copyfiles
  • Npm Check
  • Bson ObjectId
  • Apollo Server Integration Testing

Node Features

  • API Documentation with Swagger
  • REST API with Express
  • GraphQL with Apollo Server
  • Error Logging
  • Security (Hashing, Encryption, and Encoding)
  • CORS
  • Middleware
  • Route Access Levels (Admin, User, and Anonymous)
  • Deploy to Heroku
  • Serve Static Files

GraphQL Features

  • Types
  • Queries
  • Mutations
  • Resolvers
  • Directives
  • Scalars
  • Plugins

Git Features

  • Alias
  • Custom Logging
  • Branch
  • Reset
  • Amend
  • Tag
  • Stash
  • Rebase
  • Merge

Typescript Features

  • Advanced OOP
  • Interface
  • TypeAlias
  • Namespace
  • Utility Types
  • Path Modularization
  • Configurations
  • Build
  • Deploy
  • Using Breakpoints

GraphQL Features

  • Resolvers
  • Type Definitions
  • Directives
  • Scalars
  • Plugins
  • Error Handling

Test Features

  • Unit Tests
  • Integration Tests (Rest API & GraphQL)
  • Test Coverage
  • Test Doubles -Mocks
  • Stubs
  • Spies
  • Fakes

Features of MongoDb

  • Connect and Reconnect
  • Collections
  • InsertOne and InserMany
  • Find, FindOne and FindOneAndUpdate
  • DeleteMany
  • UpdateOne
  • Aggregation (Match, Group, Unwind, Lookup, AddFields, Project, Sort)
  • ObjectId
  • Upsert and ReturnOriginal
  • Push, Divide, Multiply, ArrayElemAt, Cond, Sum
  • Filter, Map, Reduce, MergeObjects, ConcatArrays

About

RESTful API in Node.js using TypeScript, Clean Architecture, and TDD. Focused on best development practices to create scalable and easy-to-maintain applications.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published