javascript - best way to implement location.path in angularjs -
as know, visit route , pass param url
$location.path('/home').search({key:'value'})
this clear every param , url , visit route, history keep
$location.search('').path('/home');
how don't keep history? transactional flow, once user paid, don't want let user able go back. know there's history service think there's more simpler way it. tried use valina javascript redirect method reloaded entire page inconsisten spa.
you can call
$location.search('').path('/home').replace();
and not create record in back-history of browser.
see documentation here.
Comments
Post a Comment