Definitely best tutorial I’ve seen for forms with shadcn, RHF and Zod. Curious if there’s a reason you validate passwords matching on the backend versus validating this on the client side? I’m just a hobby developer starting to learn about backend. Would it not be quicker to validate this as they’re filling out the form vs sending data to the backend and then waiting for an error response?
Hi thanks for the kind words! Best practice is to check if passwords match on both the client and server side. I am pretty sure you can use React Hook Forms for client side validation. Also, you should check it in backend before sending to your database.
Hey boss, which of your videos should I begin with if I'm an absolute beginner web developer with the basics of Javascript and react? I don't really know anything server-side, next, databases or anything. thanks.
No, it does not make the component re-render on every keystroke. Shadcn-ui uses react-hook-form under the hood. I will link the react-hook-form docs and if you scroll down a bit on the page, they have a demo on when the component would re-render. react-hook-form.com
so, TS keeps giving me the nasty error of type initiation is excessively deep and possibly infinite. ive been playing around for an hour and literally the basic boilerplate username form example , there it is. doesn't seem like anyone else has suffered this error for this instance but any ideas or suggestions are welcomed. I'm wondering if my TS version is out of wack or? aside from that, good vid. seems like a good workflow to form-ing, if only to settle this arggh. lol
Thanks for watching and if you can send me a picture of your dependencies in your package.json I might be able to help you out. It does seem like something is a different version that is causing your error.
It would take you 15 minutes to build this form with default html elements with react-hook-form. You just made this unneccessarily long and complicated lol
Thanks for your help Bret! I used your MERN Stack tutorial to get started on my full stack project. Really appreicate your videos!
No problem Christopher! Thanks for tuning into my channel!
thanks , have you a nice day !
Thank you! You as well!
very helpful! thanks!
Glad it was helpful!
Thank you so much for this amazing video! Your explanation is clear and very helpful. I appreciate the effort you put into making this content
Thank you for the kind words!
Hey man, great tutorials, Can you please make a whole project from scratch video using Nextjs, Mongo, Prisma, etc
Yes I am actually currently making one live on my channel. But, I will make a full project with that tech stack
Appreciate your time and the video, helped a lot!
Great Video. Thanks Brett.😀
No problem Ben!
awsome tutorial just one request sir can you please increase the text size or the zoom level please 😶🌫😶🌫
Yes I can try in the next video
Would be awesome. if you could extend this to a multi-step form in a part 2 video.
like onboarding details
address, occupation, etc.
Definitely best tutorial I’ve seen for forms with shadcn, RHF and Zod. Curious if there’s a reason you validate passwords matching on the backend versus validating this on the client side? I’m just a hobby developer starting to learn about backend. Would it not be quicker to validate this as they’re filling out the form vs sending data to the backend and then waiting for an error response?
Hi thanks for the kind words! Best practice is to check if passwords match on both the client and server side. I am pretty sure you can use React Hook Forms for client side validation. Also, you should check it in backend before sending to your database.
Great series!!!!
Thank you Greg!
Hey boss, which of your videos should I begin with if I'm an absolute beginner web developer with the basics of Javascript and react? I don't really know anything server-side, next, databases or anything. thanks.
I would recommend Brad Traversy at Traversy Media. He has really good beginner videos for React
that is a very simple and good tutorial, thnx
Thank you, glad you enjoyed my content!
Amazing explanation
Nicely done
Thank you
does this makes component rerender on every keystroke since shadcn-ui uses controlled component?
No, it does not make the component re-render on every keystroke. Shadcn-ui uses react-hook-form under the hood. I will link the react-hook-form docs and if you scroll down a bit on the page, they have a demo on when the component would re-render. react-hook-form.com
how do you fetch defaultValue from api?
It does automatically by passing in the values to your server action or your API endpoint. If you are using the Form component from Shadcn/ui
@@brettwestwooddeveloper can you make a video to demonstrate it? I still don't understand
Legend
Thanks!
can you make a video about theming not dark mode but like they make on shadcn they can change to multiple thems
Yes I can Alex
good video thanks for uploading.
How do you use the isDirty field with shadcn?
You wouldn't want to save for example if no input forms have changed?
how can we make reusable formfields for textfield or email input using shadcn ui
Thank you for creating such a valuable video! I'm curious about connecting to MongoDB data-could you provide more insights on that?
good tutorial. but the link to the github repo is not working.
Thanks for the sub Joseph! I will check it out to see why its not working!
Amazing
Thank you!
How would you deal with file uploads?
so, TS keeps giving me the nasty error of type initiation is excessively deep and possibly infinite. ive been playing around for an hour and literally the basic boilerplate username form example , there it is. doesn't seem like anyone else has suffered this error for this instance but any ideas or suggestions are welcomed. I'm wondering if my TS version is out of wack or?
aside from that, good vid. seems like a good workflow to form-ing, if only to settle this arggh. lol
Thanks for watching and if you can send me a picture of your dependencies in your package.json I might be able to help you out. It does seem like something is a different version that is causing your error.
thank you
6:05. lol "all that shhh", "stuff"
😂 yea I try not to cuss on camera, but it almost slips out sometimes.
It would take you 15 minutes to build this form with default html elements with react-hook-form. You just made this unneccessarily long and complicated lol
I guess so