Angular route accessible only through router.navigate -
is possible create angular canactivate guard let user access route if navigate through router.navigate
?
example: user creates account, , there 2 components can shown: registrationform , confirmationform. both of them have specific route configured 'registrationform', 'confirmationform'. want confirmationform accessible when user go through registrationform , on successful registration use router.navigate('confirmationform')
. want blocked when user puts www.someurl.com/confirmationform in browser address bar.
why not combine both forms single component, , use *ngif
hide/show sections depending on registration result
Comments
Post a Comment