How do I bind to the active class of a link using the new Ember router?

前端 未结 9 1622
天命终不由人
天命终不由人 2020-12-08 01:17

I\'m using Twitter Bootstrap for navigation in my Ember.js app. Bootstrap uses an active class on the li tag that wraps navigation links, rather th

9条回答
  •  醉话见心
    2020-12-08 01:41

    You can also use nested link-to's:

    {{#link-to "ccprPracticeSession.info" controller.controllers.ccprPatient.content content tagName='li' href=false eventName='dummy'}}
      {{#link-to "ccprPracticeSession.info" controller.controllers.ccprPatient.content content}}Info{{/link-to}}
    {{/link-to}}
    

提交回复
热议问题