express-validator Node.js tutorial

Veröffentlicht am: 29 März 2021
auf dem Kanal: Jan Goebel
37,456
576

🔥More exclusive content: https://productioncoder.com/you-decid...
Twitter:   / _jgoebel  
Blog: https://productioncoder.com
Website: https://jangoebel.com
Code: https://github.com/productioncoder/no...

In this video, we take a look at the express-validator npm package. This package allows you to validate incoming request payloads and it allows you to check whether the payload conform to the format that you are expecting.

We cover how to create request body validation middlewares and how properly organize your project with express-validator.

00:00 express-validator project setup with Typescript
03:10 creating a express server with validation middleware
04:52 understanding express-validator chains
06:52 trying out request-validator
09:25 exists validator chain with falsy checks
12:07 moving request body validation to its own middleware
15:36 moving express validator schema checks to a separate file
18:50 moving the routes to another
21:17 customizing error messages in express-validator
22:45 conclusion


Auf dieser Seite können Sie das Online-Video express-validator Node.js tutorial mit der Dauer stunde minuten sekunde in guter Qualität ansehen, das der Benutzer Jan Goebel 29 März 2021 hochgeladen hat, den Link mit Freunden und Bekannten teilen, dieses Video wurde auf Youtube bereits 37,456 Mal angesehen und es wurde von 576 den Zuschauern gefallen. Viel Spaß beim Betrachtenden Zuschauern gefallen!