Answers for "reload strategy angular"

0

refresh page angular

refresh(): void {
    window.location.reload();
}
Posted by: Guest on March-16-2021
4

How to Reload a Component in Angular

reloadComponent() {
  let currentUrl = this.router.url;
      this.router.routeReuseStrategy.shouldReuseRoute = () => false;
      this.router.onSameUrlNavigation = 'reload';
      this.router.navigate([currentUrl]);
  }
Posted by: Guest on September-25-2020

Code answers related to "TypeScript"

Browse Popular Code Answers by Language