« All deprecation guides

Deprecation Guide for Model param in render helper

until: 3.0.0
id: model-param-in-code-render-code-helper

Using the model param in the {{render helper is deprecated in favor of using components. Please refactor to a component and invoke thusly:

For example, if you had:

{{render 'foo-bar' someModel}}
app/templates/foo-bar.hbs
<p>{{someProp}} template stuff here</p>
app/controllers/foo-bar.js
export default Controller.extend({
  someProp: Ember.computed('model.yolo', function() {
    return this.get('model.yolo');
  })
});

Would be refactored to:

{{foo-bar model=someModel}}
<p>{{someProp}} template stuff here</p>
export default Component.extend({
  someProp: Ember.computed('model.yolo', function() {
    return this.get('model.yolo');
  })
});