Skip to content

Instantly share code, notes, and snippets.

@stefanpenner
Created November 27, 2016 08:08
Show Gist options
  • Save stefanpenner/e37fb6e7d7f5da27622e44d1a319e7bb to your computer and use it in GitHub Desktop.
Save stefanpenner/e37fb6e7d7f5da27622e44d1a319e7bb to your computer and use it in GitHub Desktop.
strange-issue
import Ember from 'ember';
export default Ember.Controller.extend({
init() {
this._super(...arguments);
this.set('items', []);
Ember.run.later(() => this.set('items', [1]), 1000);
},
toString() {
return this.get('length');
},
length: Ember.computed('items.length', function() {
return this.get('items.length');
}),
});
{
"version": "0.10.6",
"EmberENV": {
"FEATURES": {}
},
"options": {
"use_pods": false,
"enable-testing": false
},
"dependencies": {
"jquery": "https://cdnjs.cloudflare.com/ajax/libs/jquery/1.11.3/jquery.js",
"ember": "2.9.0",
"ember-data": "2.9.0",
"ember-template-compiler": "2.9.0",
"ember-testing": "2.9.0"
},
"addons": {}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment