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

Popular posts from this blog

php - How to display all orders for a single product showing the most recent first? Woocommerce -

asp.net - How to correctly use QUERY_STRING in ISAPI rewrite? -

angularjs - How restrict admin panel using in backend laravel and admin panel on angular? -