Angular 12 tutorial in Hindi #37 Reactive form Validations
HTML-код
- Опубликовано: 16 сен 2024
- In this angular 12 version video, we learn how to apply validations on Reactive form in angular 12. This video is made by anil Sidhu in the Hindi language.
Reactive Form Validation
Use Form from the last video
Import Validators
Apply validations
Define Getter for fields
Show errors and Disable button
code link github.com/ani...
React js Latest Playlist in hindi : • React tutorial for beg...
inst id: @code.steps
after some video, I watch your video then my basic concept clear.
bhtreen, awesome aaj asa lga ki shi mein kuch tagda bnaya h
You missed to add video on validation through 'Template driven Form' & also introduction part of 'Reactive form'
Check his English series on it
You will find out both of them..
very well explained ! Than You Anil
Thank you for the lesson !!!
hello sir
me=>> name: new FormControl(' ',[Validators.required, Validators.pattern('[a-zA-Z]+$')]), =>> kr rhi hu but mere validation hide nhi hor rhi h jab me kuchh bhi input kru to.. please sir reply me soon please.
thank you
Those who are getting invalid error message in html template....
function should be get
Eg:
get user() {return}
And not : getuser() {return}
There is a space between get and the name of function....
Get is a separate keyword
Thanks Sir gee
How to write different error messages for different type of validation
For example for required the msg will be this field is required for min length msg will be min length is ...
if we had multiple fields then we have to define separate function for each field.
Thank you sir 👍👍
How to give separate Error message of each validation, in case of multiple validations in a field ?
till 50 video of this series, is enough to crack interview?
laajwaab sir gee
Good morning sir ji
Validation through template driven form?
Hello bhaiya, I didn't understood the *ngIf condition. I understood why we used "user.invalid && user.touched" but I why we used "user" at the start in the condition with these two other condition. what does it signify?
It is checking if the user property is not undefined
Super 👍
Thank you! Cheers!
I used every steps of your but the invalid message doesn't appear
user:new formControl(' ',[validators.required])
Validator must be second parameter
nice
Thanks
Is video se pahle wala video sequence main nahin aa raha h
Meine same step follow Kiya but invalid wala msg appear nhi ho raha hai..
name: new FormControl(' ',[Validators.required, Validators.pattern('[a-zA-Z]+$')]), try once more
Video39 is repeated, I think you mistakenly uploaded the wrong one. Kindly correct.
I will check it
in case of facing Invilid error on html template! use question mark!!
*ngIf="userNameValidate?.invalid
tried but it's not working
*ngIf="user && user?.invalid && user?.touched
it's showing the same error Property 'invalid' does not exist on type
@@manishchoudhary2722 use hasError method saw any ref from google!
@@manishchoudhary2722 use hasError method , take refrence from stackoverflow or chatgpt
Thanks sir
Welcome
Video39 is repeated, I think you mistakenly uploaded the wrong one. Kindly correct.
Sure
@@codestepbystep till now it was not corrected