DEV Community

Cover image for Getting Started With NestJS

Getting Started With NestJS

Santosh Yadav on January 02, 2020

This is the first part of the series of articles on the Node.js framework known as NestJS, in this article we will see why and how to use NestJS. ...
Collapse
 
jcarlosweb profile image
Carlos Campos • Edited

Another option with Node+Express is github.com/TypedProject/ts-express...,
With TSED you don't need to create modules, so with NestJS it forces you to do it, which I don't understand and which makes the image put in Post look bad. Because with the controllers you have to create a module, while with TSED, you don't need that.

Collapse
 
santoshyadavdev profile image
Santosh Yadav This is Learning

The reason for modules is, the framework is heavily inspired by Angular, and I can understand many Javascript developers are not used to such pattern, but it makes structuring large apps really easy.

Collapse
 
jcarlosweb profile image
Carlos Campos

It would be ideal if NestJS did not force you to create modules, that is to say to have the option to create them or not.

Collapse
 
vinceramces profile image
Vince Ramces Oliveros

One thing that NestJS lacks is the deployment of their application.

architecture
Your diagram does not have Data Transfer Object(DTO) which is essential to have your Controller to validate(using class validator) before it gets to the Service Layer(which communicates to the Database).

Well, since it is just a "Getting Started" article, you might as well provide your DTO or the interface of that component in the next series.

Collapse
 
santoshyadavdev profile image
Santosh Yadav This is Learning

Yeah I will cover them in upcoming articles, here they are not mandatory. So skipped from the diagram.