Skip to content

Instantly share code, notes, and snippets.

import Ember from 'ember';
export default Ember.Controller.extend({
appName: 'Ember Twiddle',
init(){
var model = Ember.Object.create({
title:"My Cool Model",
items:[
{name:"item1",isSelected:true},
{name:"item2",isSelected:false}
]
@jeradg
jeradg / application.controller.js
Last active January 11, 2016 16:48 — forked from denzo/application.controller.js
Computed Properties with @each (working - Ember 2.0.2)
import Ember from 'ember';
let lastId = 0;
export default Ember.Controller.extend({
rootItems: Ember.computed.filter('owner.items', function(item) {
return item.get('parent.content') === null;
}).property('[email protected]'),
owner: Ember.computed(function() {