Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

angular-ui router reload view

I'm using angular-ui's router (v0.2.0) in a project and we're trying to reload a view. I've tried $state.transitionTo and also $state.go, but neither seem to do anything. Would anyone know how to do a reload?

Thank you!

like image 766
dzm Avatar asked Nov 30 '13 06:11

dzm


1 Answers

The 3rd parameter of $state.go takes an options object which has a reload property, so doing something like

$state.go('resources', {start: $stateParams.start}, {reload:true});

Should do the trick - on the latest version I can confirm it works.

like image 53
Richard Avatar answered Sep 21 '22 08:09

Richard