Angular route guards

Поделиться
HTML-код
  • Опубликовано: 28 дек 2024

Комментарии • 42

  • @BakarGames
    @BakarGames 3 года назад +1

    Thanks Venkat a lot i learned a lot of things from u.... u will be always remembered and i will always recommended your all tutorial to all programmers..

  • @daviddonadze221
    @daviddonadze221 6 лет назад +13

    After Angular can you please start ReactJS Videos. There are so many ReactJS Videos but No One Explains the way you do. You are Legend

    • @hassansall7181
      @hassansall7181 6 лет назад

      Indeed

    • @anuragranjan6739
      @anuragranjan6739 6 лет назад

      Hello @David , I think you are a Angular Developer so you are on this video Series , as you have asked to upload React tutorial nearly 5 month back so I just wanted to ask did you completed React after Angular
      because I am a Angular Developer and I am planning to learn React , But I don't know if I will be comfortable with React after learning Angular , and how much time it took to adopt react , as A Angular developer .. was it confusing ..?

  • @bmiguelmf
    @bmiguelmf 5 лет назад +1

    The greatest of them all. thank you a lot!!!

  • @jonathansansens
    @jonathansansens 5 лет назад +6

    I had an error on ViewChild: Expected 2 arguments, but got 1.
    Fixed this error:
    @ViewChild('employeeForm', {static: false}) public createEmployeeForm: NgForm;

  • @sanjibanichoudhury7517
    @sanjibanichoudhury7517 6 лет назад +2

    NgForm in component is undefined, what to import

  • @srinathreddy4910
    @srinathreddy4910 3 года назад

    Superb explanation thanks venkat

  • @itsimpl6257
    @itsimpl6257 5 лет назад +1

    Is it possible to use custom confirmation box such as material dialog instead of window.confirm()?

    • @AlokKumar-fh9gy
      @AlokKumar-fh9gy Год назад

      Hello
      Could you please tell if this id possible

  • @tharund3572
    @tharund3572 6 лет назад +2

    the guard is showing the confirm alert by clicking submit button also?

    • @Csharp-video-tutorialsBlogspot
      @Csharp-video-tutorialsBlogspot  6 лет назад +2

      Good observation Tharun. Sorry, I missed to test saving the data. To fix this all we have to do is reset the form. I will record and upload a video soon that explains how to do this. Thank you very much for taking the time to let us know about this.

    • @kumarswamy2900
      @kumarswamy2900 6 лет назад

      R u uploaded this video for Q)the guard is showing the confirm alert by clicking submit button also?

    • @souvikpodder7187
      @souvikpodder7187 6 лет назад

      @@kumarswamy2900 do {yourFormName}.reset(); on Submission on your form it will work

    • @mohamed.elzallat
      @mohamed.elzallat 4 года назад

      @@souvikpodder7187 thanks man it worked

  • @pandarzzz
    @pandarzzz 6 лет назад +1

    Thank you for sharing this informative video! 🐻🖐🏻

  • @lathakumari626
    @lathakumari626 Год назад

    Great explanation

  • @continental_drift
    @continental_drift 6 лет назад

    Rather than on the route, is it possible to guard the destruction of the form?

  • @janarthanasp
    @janarthanasp 6 лет назад +2

    If we hit browser back button once, the guard is called and select Cancel. Then if we click the browser back button again, the actual back happens. Seems an open Angular bug.

  • @aasthawadhwa2575
    @aasthawadhwa2575 3 года назад

    Thankyou for this video, helped me a lot!

  • @khatkolekomal
    @khatkolekomal 4 года назад

    Very nicely explained sir!!
    Instead of register service in module provider , is it fine if I register in provider of createEmployee component itself within decorator?

  • @gkmishra2009
    @gkmishra2009 5 лет назад

    what are scenario where we can use custom directives in projects??

  • @siva6388
    @siva6388 6 лет назад +1

    Sir..is it possible to use the custom modal popup instead of using the confirm dialog box?

    • @anuragranjan6739
      @anuragranjan6739 6 лет назад

      You can try ngx-bootrap modals valor-software.com/ngx-bootstrap/#/modals

  • @ashutoshshrestha8745
    @ashutoshshrestha8745 5 лет назад

    this works just fine, however it still shows that message after i make changes to the form update it and try to navigate to another route. How do i prevent that.

  • @hassansall7181
    @hassansall7181 6 лет назад +1

    Plz can you make a series on SignalR

  • @orz5516
    @orz5516 5 лет назад

    any1 knows how to do guard that controls multiple components ? (with a condition common to all the components)
    thanks !

  • @RakeshKumar-ou8ff
    @RakeshKumar-ou8ff 5 лет назад

    How to work on same component

  • @salmanchowdarym1110
    @salmanchowdarym1110 6 лет назад

    Simply amazing

  • @jacksm8709
    @jacksm8709 4 года назад

    best guard tutorial.....

  • @ihsanullah4058
    @ihsanullah4058 6 лет назад

    Great sir...its too helfull

  • @murkmemon6355
    @murkmemon6355 4 года назад

    candeactivate guard does not work for me. code is simple and i have performed all your steps show in video instead of this it is not showing alert box with message. any suggestion?

  • @belmiris1371
    @belmiris1371 6 лет назад

    Thank you!

  • @csdias2004
    @csdias2004 6 лет назад

    Thank you

  • @nigochen6665
    @nigochen6665 3 года назад

    Thanks

  • @swethapallavig5726
    @swethapallavig5726 6 лет назад +1

    Getting an error - VM39061 core.js:1665 ERROR Error: Uncaught (in promise): TypeError: Cannot read property 'dirty' of undefined
    TypeError: Cannot read property 'dirty' of undefined
    I'm using Reactive Form. Please help

    • @kaischaabane6978
      @kaischaabane6978 6 лет назад

      check if you are added at the right place
      {
      path: 'create',
      component: CreateEmployeeComponent,
      canDeactivate: [CreateEmployeeCanDeactivateGuardService]
      },

    • @shri11.11
      @shri11.11 3 года назад

      No need of using @viewchild, directly u can write if(component.formname.dirty)