Built-in Views Edit Page


Ember comes pre-packaged with a set of views for building a few basic controls like text inputs, check boxes, and select lists.

They are:

Ember.Checkbox

1
2
3
4
<label>
  {{view Ember.Checkbox checked=model.isDone}}
  {{model.title}}
</label>

Ember.TextField

1
2
3
4
5
6
App.MyText = Ember.TextField.extend({
  formBlurred: null, // passed to the view helper as formBlurred=controllerPropertyName
  change: function(evt) {
    this.set('formBlurred', true);
  }
});

Ember.Select

1
2
3
4
5
6
{{view Ember.Select viewName="select"
                    content=people
                    optionLabelPath="model.fullName"
                    optionValuePath="model.id"
                    prompt="Pick a person:"
                    selection=selectedPerson}}

Ember.TextArea

1
2
3
var textArea = Ember.TextArea.create({
  valueBinding: 'TestObject.value'
});