Skip to content

Instantly share code, notes, and snippets.

@xtian
Forked from bobbywilson0/controller.js
Last active August 29, 2015 13:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save xtian/8694170 to your computer and use it in GitHub Desktop.
Save xtian/8694170 to your computer and use it in GitHub Desktop.
TypeFast.GameRoute = Ember.Route.extend({
model: function() {
return this.store.find('quote', Math.floor((Math.random()*3)+1));
},
setupController: function(controller, model) {
controller.set('model', model);
}
});
var obj = {
quote: model.body, // undefined is not an object
word: ''
}
TypeFast.GameController = Ember.Controller.extend(obj);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment