AngularJS change route by ng-click using ui-router

前端 未结 1 591
伪装坚强ぢ
伪装坚强ぢ 2020-12-10 01:45

How can I change the route.state using ng-click instead of a link applying ui-sref.

I\'ve tried this:

相关标签:
1条回答
  • 2020-12-10 02:17

    Check out the ui-router documentation wiki.

    The best solution is to use $state.go(). e.g., $state.go('recorder.options')

    Here's the link to the specific function in the documentation: https://github.com/angular-ui/ui-router/wiki/Quick-Reference#stategoto--toparams--options

    0 讨论(0)
提交回复
热议问题