Route#loading event

loading (transition, route) public Defined in packages/ember-routing/lib/system/route.js:612 Available since 1.2.0 The loading action is fired on the route when a route's model hook returns a promise that is not already resolved. The current Transition object is the first parameter and the route that triggered the loading event is the second parameter. App.ApplicationRoute = Ember.Route.extend({ actions: { loading: function(transition, route) { let controller = this.controllerFo

TextSupport#bubbles

bubblesBooleanprivate Defined in packages/ember-views/lib/mixins/text_support.js:172 Whether the keyUp event that triggers an action to be sent continues propagating to other views. By default, when the user presses the return key on their keyboard and the text field has an action set, the action will be sent to the view's controller and the key event will stop propagating. If you would like parent views to receive the keyUp event even after an action has been dispatched, set bubbles to tru

ViewTargetActionSupport#$()

$ (selector) JQuerypublic Defined in packages/ember-views/lib/mixins/view_support.js:96 Returns a jQuery object for this view's element. If you pass in a selector string, this method will return a jQuery object, using the current element as its buffer. For example, calling view.$('li') will return a jQuery object containing all of the li elements inside the DOM element of this view. Parameters: selector [String] a jQuery-compatible selector string Returns: JQuery the jQuery objec

Observable#toggleProperty()

toggleProperty (keyName) Booleanpublic Defined in packages/ember-runtime/lib/mixins/observable.js:473 Set the value of a boolean property to the opposite of its current value. starship.toggleProperty('warpDriveEngaged'); Parameters: keyName String The name of the property to toggle Returns: Boolean The new property value

DS.Errors#length

length{Number} Defined in addon/-private/system/model/errors.js:194 Total number of errors.

DS.Model#didDefineProperty()

didDefineProperty (proto, key, value) Defined in addon/-private/system/relationships/ext.js:102 This Ember.js hook allows an object to be notified when a property is defined. In this case, we use it to be notified when an Ember Data user defines a belongs-to relationship. In that case, we need to set up observers for each one, allowing us to track relationship changes and automatically reflect changes in the inverse has-many array. This hook passes the class being set up, as well as the ke

Ember.computed.bool()

bool (dependentKey) Ember.ComputedPropertypublic Defined in packages/ember-runtime/lib/computed/computed_macros.js:183 A computed property that converts the provided dependent property into a boolean value. let Hamster = Ember.Object.extend({ hasBananas: Ember.computed.bool('numBananas') }); let hamster = Hamster.create(); hamster.get('hasBananas'); // false hamster.set('numBananas', 0); hamster.get('hasBananas'); // false hamster.set('numBananas', 1); hamster.get('hasBananas'); // true

Input Helpers

Input Helpers The {{input}} and {{textarea}} helpers in Ember.js are the easiest way to create common form controls. The {{input}} helper wraps the built-in Ember.TextField and Ember.Checkbox views, while {{textarea}} wraps Ember.TextArea. Using these helpers, you can create these views with declarations almost identical to how you'd create a traditional <input> or <textarea> element. Text fields {{input value="http://www.facebook.com"}} Will become: <input type="text" value="

Relationships

Relationships Ember Data includes several built-in relationship types to help you define how your models relate to each other. One-to-One To declare a one-to-one relationship between two models, use DS.belongsTo: app/models/user.js import DS from 'ember-data'; export default DS.Model.extend({ profile: DS.belongsTo('profile') }); app/models/profile.js import DS from 'ember-data'; export default DS.Model.extend({ user: DS.belongsTo('user') }); One-to-Many To declare a one-to-many relati

HashLocation#setURL()

setURL (path) private Defined in packages/ember-routing/lib/location/hash_location.js:72 Set the location.hash and remembers what was set. This prevents onUpdateURL callbacks from triggering when the hash was set by HashLocation. Parameters: path String