Answers for "how to set routes in angular"

1

angular go to route

import {Router} from '@angular/router';

constructor(private router: Router) {}

navigateToLogin() {
   this.router.navigateByUrl('/login');
}
Posted by: Guest on March-22-2021
1

angularjs change route js

window.location.hash = 'new-route';
Posted by: Guest on November-16-2021

Code answers related to "Javascript"

Browse Popular Code Answers by Language