CanDeactivate Route Guard - Angular (Tutorial #26)
HTML-код
- Опубликовано: 8 сен 2024
- CanDeactivate Route Guard in Angular - Tutorial no. 26
The Angular CanDeactivate guard is called, whenever we navigate away from the route before the current component gets deactivated.
The best use case for CanDeactivate guard is the data entry component.
The user may have filled the data entry and tries to leave that component without saving his work.
The CanDeactivate guard gives us a chance to warn the user that he has not saved his work and give him a chance to cancel the navigation
Use this link to share this video : • CanDeactivate Route Gu...
You can also visit my following videos:
CanActivateRouteGuard: • CanActivate Route Guar...
CanActivateChild Route Guard: • CanActivateChild Route...
Nested Routing: • Nested Routes - Angula...
Router Parameters: • Route Parameters - Ang...
Routing: • Routing - Angular (Tut...
Angular Tutorial Series:
• Introduction- Angular ...
Follow me on:
►RUclips : / nishasingla
►Facebook : / angularjs4beginners
►LinkedIn : / nishasingla
If you have missed my previous video on CanActivateChild Route guard. Take a look
ruclips.net/video/Z0PNK-n5iv0/видео.html
vedio is very nice ,crisp,clear,to the point ,love u mam
the way u r explaining is awesome...thanks a lot😍
you are great at teaching....ur content is good...its just that you are teaching as if you are teaching to a class....just speak as if you are teaching to a friend....makes us listen for a long time....thanks again for the content nisha.
Appreciate the way you teach in correct and concise manner. Can you also cover ngrx(state management) and rxjs in angular since there are very limited resources regarding these topics on youtube.
Great explanation. I am working with angular since last 3 years but never see this kind of short and crisp explanation video. Thanks for it.
Thank you i was looking at a tutorial and they didn't explain why interface was required thank you for explaning this
Glad to know it helped 😀👍🏻
great Nisha clean explanation your videos are way better than plural sight videos charging several bucks .keep doing more videos thanks in advance.
thanks for this great explanation my every single question is answered in your video......you are great explaner!
Thank you for uploading new content on Routes. I gone through all your previous videos on Angular.
Thank you 😊
Thank for the wonderful lecturers Angular.I have been recommending your channel for Angular videos to my colleague's.
Thank you . Glad to know you liked it . Keep learning and sharing
Unbelievable yar...very interesting to watch your videos, like way of your teaching and explanation. Thanks a lot 🙌
Thank you very much for providing this. I request to you please provide more videos for CRUD operations.
content is very good
THANK YOU !
Thanks for the awesome learning experience
My pleasure 😀😀
Thanks for the video! It was very useful
😊😊🙏🙏
Excellent.. 🥇
Truly amazing.. Good content.
Thanks
Very good ,especially the generic solution ! thank u
Tq for great explanation please make videos on
Best practices of angular
Angular Form validations
Dependency Injection
Components hooks with best practices
awesome
Thank you 😊
Awesome
Thank u so much
Most welcome 😊
Video is osm ma'am make a video on locale and internationalisation
Thank you Lokesh
How to create custom dialog using can deactivate guard?
if(component.canLeave)
.'canLeave' is undefined, even though it is declared in my component as it implements the interface we exported in the UnsavedChangesGuard.
I'm not sure what i'm doing wrong.
EDIT:
It was because the returned 'component' from the 'canLeave()' method was returning the parent component instead of the child component.
Iam pardha as new to angular. Could you please suggest best architecture for consuming services
Can i notify user if they close browser or type in the route? Im confused about using interfaces to make guards reusable. Thanks
Can u plz again explain canActivateChild once again clearly plz
Just wanna ask for whole form how we can target to check whether it got dirty ?
How can we use this for a complete form.
Hi Nisha, by default the boolean is false???
If we have 20 fields then have we required to check for all the fields or common things?
can you please make some videos on forms
How to detect page load/ page refresh when unsaved form?
Could you please let me know, How stop not to logout the application when model is dirty.
i need full angular 11 material
canDeactivate has called twice in my case, can you please explain why?
Mama apne sirf username dirty hai kya wo check kiya agr pure page ki koi form field chech krni ho dirty hai kya to kaise kre
Sorry mam* kehna tha
May be you can upload source code to github ?