angular - Refresh Angular2 page progamatically without all app reloading -


what method refresh route in angular 2 programatically in order trigger oninit hook?

maybe there single method refresh current route.

from:

https://angular.io/docs/ts/latest/api/router/router-class.html

renavigate() : promise<any>

navigates either last url navigated to, or last url requested if router has yet navigate.

inject router , call renavigate() method:

this._router.renavigate();


Comments

Popular posts from this blog

sublimetext3 - what keyboard shortcut is to comment/uncomment for this script tag in sublime -

java - No use of nillable="0" in SOAP Webservice -

ubuntu - Laravel 5.2 quickstart guide gives Not Found Error -