NestJS through the eyes of developer

Building NestJS API from scratch - episode #1

2023

@ValentinKononov

What we'll cover today

# plan
  • Principles of building sustainable API
  • NestJS modules
  • Declarative approach
  • Feature Modules Approach
  • Dependency Injection
  • Parameters handling
  • Hands-on experience with module, controller, service
  • Have fun with swagger
# repo

Samples added to repo

2023

@ValentinKononov

https://github.com/valentinkononov/nester
# idea

How Good API can look like

  • Works as expected
  • Convenient Layered Structure
  • Documentation provided
  • Secure
  • Requests are validated
  • Performance is acceptable
  • Test coverage
  • Logging and error handling
  • Scalable
  • CI/CD
# framework

NestJS parts

Modules

Controllers

Dependency Injection

Service, Provider

Routing

Request Pipeline...

# framework

NestJS Module

Feature Module

Service

Repository

Controller

Imports

Exports

# code

Let's code it!

2023

@ValentinKononov

NestJS through the eyes of developer - part#1

By Valentin Kononov

NestJS through the eyes of developer - part#1

* Principles of building sustainable API * NestJS modules * Declarative approach * Feature Modules Approach * Dependency Injection * Hands on experience with module, controller, service * Parameters handling * Have fun with swagger

  • 127