“Jak ponownie załadować tę samą stronę w Angular 8” Kod odpowiedzi

Jak ponownie załadować komponent w kątowym

reloadComponent() {
  let currentUrl = this.router.url;
      this.router.routeReuseStrategy.shouldReuseRoute = () => false;
      this.router.onSameUrlNavigation = 'reload';
      this.router.navigate([currentUrl]);
  }
Courageous Chamois

Komponent przeładowania kątowego

reloadCurrentRoute() {
    let currentUrl = this.router.url;
    this.router.navigateByUrl('/', {skipLocationChange: true}).then(() => {
        this.router.navigate([currentUrl]);
    });
}
Courageous Chamois

Jak ponownie załadować tę samą stronę w Angular 8

No mames, simplemente usa el reload... Por qué en los foros siempre se las quieren lucr y terminan colocando vainas que ni sirven
Elegant Earthworm

Odpowiedzi podobne do “Jak ponownie załadować tę samą stronę w Angular 8”

Pytania podobne do “Jak ponownie załadować tę samą stronę w Angular 8”

Przeglądaj popularne odpowiedzi na kod według języka

Przeglądaj inne języki kodu