Backend API Validation Tutorial w/ YUP and ExpressJS

  Рет қаралды 12,826

PedroTech

PedroTech

Күн бұрын

Пікірлер: 40
@bruhgoaway4876
@bruhgoaway4876 2 жыл бұрын
Been watching many of your backend/API-related videos recently, and I'm astonished to see how good they hold up in terms of quality and content. Even after completing several projects, I still gain that extra bit of clarity from these videos that help make working on a JS backend more intuitive for me.
@ead5590
@ead5590 2 жыл бұрын
This is great! I have implemented YUP on the backend with Prisma along with MySQL. Validation is being done with YUP for the input field values and Prisma checks if the email exists on the DB. That's a whole lot of validation going on.. And I love it! 😆 Thanks a lot Pedro! ✌🏻
@ddbros6603
@ddbros6603 3 жыл бұрын
it just amazing and also your explanation is excellent Thank You!
@paulinha-19
@paulinha-19 Жыл бұрын
Amazing, thanks for video!
@PandaPiper
@PandaPiper 3 жыл бұрын
Pedro: “I’m gonna put something crazy” Pedro: ‘types name’ 😂😂😂 But for real great video! Could you show how to handle the authentication after validating? Or would you just use Firebase like you did in your other video?
@renatomignogna6895
@renatomignogna6895 3 жыл бұрын
Hey Pedro, thanks for this - great tutorial!
@faris.abuali
@faris.abuali 2 жыл бұрын
Thanks Pedro! 😀 I see that 'yup' is similar to 'express-validator' package
@otaviopontes6637
@otaviopontes6637 3 жыл бұрын
Boa Pedro, ajudou pakas 👍
@PedroTechnologies
@PedroTechnologies 3 жыл бұрын
Fico feliz! Obrigado!
@danielyabu
@danielyabu 2 жыл бұрын
Thanks man, it helped a lot! BTW, your English is great. I just heard you pronouncing 'buddy' instead of 'body'... LOL
@PedroTechnologies
@PedroTechnologies 2 жыл бұрын
Yes hahaha this was a long time ago and my friends made fun of me for how i said it hahaha i say it correctly now!
@wangsunhakhun4314
@wangsunhakhun4314 2 жыл бұрын
really helpful.. save so much pain..
@shin9850
@shin9850 3 жыл бұрын
thaks man, it help me a lot
@mohamedyoussef8835
@mohamedyoussef8835 3 жыл бұрын
Awesome Tutorial.... Thank you +++++++++++
@jean-louisgouwy
@jean-louisgouwy 4 жыл бұрын
What it could be cool would be to send all the errors directly in the formatted error response :)
@n1ght_walker536
@n1ght_walker536 3 жыл бұрын
This is exactly what brought me here. Sighs, disappointed I must say.
@ohyeah3514
@ohyeah3514 2 жыл бұрын
how to do that
@majidshah48
@majidshah48 2 жыл бұрын
set "abortEarly" to false example:: await schema.validate({ name: 'jimmy', age: 24 } , { abortEarly : false});
@Mercio2
@Mercio2 2 жыл бұрын
Thanks!
@fri9268
@fri9268 4 жыл бұрын
Hello i watching your videos and they helped me a lot because i am new there and i learn React and everything around it. Now i trying use this validation with mySql on the same way asi you show in CRUD tutorial but i have a BIG problem now, i using this validation with MySQL because when i use middleware with db.querry, server go down with error ERR_HTTP_HEADERS_SENT' and i really do not know what with it and i need it a lot now for my school work. Can you make video how to use yup with mysql query. Thank you very much that you are there.
@PedroTechnologies
@PedroTechnologies 4 жыл бұрын
Hey, so yup isn't meant to validate mysql queries in particular. What you validate is the variables you send in the query. So it would be exactly like this, you wouldn't have to touch mysql. If the error continues, could you paste your code here?
@nicolajslvsten4978
@nicolajslvsten4978 3 жыл бұрын
how to display server response on the client using html?
@maxmaksum4673
@maxmaksum4673 4 жыл бұрын
great
@PedroTechnologies
@PedroTechnologies 4 жыл бұрын
Thank you!
@Shellflower1234
@Shellflower1234 4 жыл бұрын
Amazing!!
@PedroTechnologies
@PedroTechnologies 4 жыл бұрын
Thanks!!
@hussanjhjhjhjhjh6903
@hussanjhjhjhjhjh6903 29 күн бұрын
thanks bro but i have one recommendation please do not use the high ore function at the backend controller fiels that handles your queries only remove te double async res, and req obj from the function use simple async functions for the backend but in middleware you can use this request
@medAmineRg
@medAmineRg 3 жыл бұрын
great video
@usmanmughal5916
@usmanmughal5916 4 жыл бұрын
Firebase project
@PedroTechnologies
@PedroTechnologies 4 жыл бұрын
Firebase is awesome! I am planning on a video talking about login with firebase!
@usmanmughal5916
@usmanmughal5916 4 жыл бұрын
@@PedroTechnologies yea with storage for pics
@usmanmughal5916
@usmanmughal5916 4 жыл бұрын
@@PedroTechnologies can i know what is ur age? Iam 18
@PedroTechnologies
@PedroTechnologies 4 жыл бұрын
Yeah, should definitely do one!
@PedroTechnologies
@PedroTechnologies 4 жыл бұрын
Damn hahaha Im 19 lmaoo You are a prodigy then, when I was 8 no one in my house had a computer hahaha
@medAmineRg
@medAmineRg 2 жыл бұрын
hey you dont need to return next() that will cause a serious problem. you have just to call it. otherwise great tutoriel!
@medAmineRg
@medAmineRg 2 жыл бұрын
@LALIT BISHT great to hear that my comment help, haha same here it took me like 6 hours to figure that problem, you welcome bro
ExpressJS Middleware Tutorial - NodeJS Middleware For Beginners
12:54
Вопрос Ребром - Джиган
43:52
Gazgolder
Рет қаралды 3,8 МЛН
КОНЦЕРТЫ:  2 сезон | 1 выпуск | Камызяки
46:36
ТНТ Смотри еще!
Рет қаралды 3,7 МЛН
Form Validation In React Using YUP Tutorial
14:22
PedroTech
Рет қаралды 96 М.
Uploading Images with Multer | NodeJS and ExpressJS
15:34
PedroTech
Рет қаралды 202 М.
MVC Pattern Explained Easy | MVC Tutorial (Example in NodeJS)
17:05
I tried 8 different Postgres ORMs
9:46
Beyond Fireship
Рет қаралды 445 М.
Express JS #10 - Validation
31:33
Anson the Developer
Рет қаралды 16 М.
Express JS #9 - Middleware
21:42
Anson the Developer
Рет қаралды 11 М.
What are HTTP Headers in API
17:38
Piyush Garg
Рет қаралды 94 М.
Вопрос Ребром - Джиган
43:52
Gazgolder
Рет қаралды 3,8 МЛН