【问题标题】:Emberjs - How to access the current state or route name in RC1?Emberjs - 如何访问 RC1 中的当前状态或路由名称?
【发布时间】:2013-02-25 11:20:11
【问题描述】:

在 RC1 中,如何获取全局的 currentstatename 或 current route name?

更具体的替代语法: App.get('router').currentState.name;

【问题讨论】:

标签: ember.js router


【解决方案1】:

看看这个问题的答案:Ember App.Router.router.currentState undefined

简短回答:当前状态存储在名为“currentPath”的 ApplicationController 中。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2014-10-11
    • 2022-07-21
    • 1970-01-01
    • 1970-01-01
    • 2016-04-06
    • 1970-01-01
    • 2017-11-28
    相关资源
    最近更新 更多