DEPRECATION: The `bind-attr` helper
See original GitHub issueIn ember 1.13.x and 2 beta, bind-attr
is deprecated.
Any idea when this will be resolved?
Issue Analytics
- State:
- Created 8 years ago
- Comments:11 (1 by maintainers)
Top Results From Across the Web
Ember bind-attr deprecated, how to rewrite using new ...
I'm an Ember newbie, and am trying to alter the following handlebars/template line of code to not use the deprecated bind-attr approach ...
Read more >Deprecations Added in Ember 1.x
bind-attr. Ember 1.11 introduced new syntax for using dynamic content in attributes. In 1.10 your only option was to use the bind-attr helper:...
Read more >Expressions | Handlebars
Handlebars expressions are the basic unit of a Handlebars template. You can use them alone in a {{mustache}} , pass them to a...
Read more >legacy-bind-attr - Ember Observer
Ember 2.0 deprecated {{bind-attr}} . This addon enables the bind-attr helper within your Ember 2.0 applications.
Read more >What's New in Ember 2.0? - SitePoint
ArrayController and ObjectController have been deprecated in favor ... In past, the {{bind-attr}} helper was used to bind properties to DOM ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@hwhelchel
bind-attr
will be removed in Ember.js 2.0. Unfortunately it seems like there is no entry in the deprecation guide for this.You should replace
bind-attr
statements with htmlbars-style attribute bindings. For example:Can be rewritten as:
The more complex case of a class binding:
Can be rewritten as:
Multiple bindings can of course be used. A complex example:
The latter above demonstrating use of a 3rd party
t
helper for translation. This unified style of bindings is easier for new developers to learn (though us old hands may missbind-attr
) and simpler (no special syntax forclass
).What about concatenated classnames? How would you do it in HTMLBars?