Skip to content

Instantly share code, notes, and snippets.

@robbiespeed
Created January 9, 2016 00:53
Show Gist options
  • Save robbiespeed/a2119565b27e455866a7 to your computer and use it in GitHub Desktop.
Save robbiespeed/a2119565b27e455866a7 to your computer and use it in GitHub Desktop.
set return
import Ember from 'ember';
const { computed } = Ember;
export default Ember.Controller.extend({
appName:'Ember Twiddle',
thing: computed(function () {
let thing = this.set('appName', 'Ember');
return thing;
})
});
<h1>Welcome to {{appName}}</h1>
{{thing}}
<br>
<br>
{{outlet}}
<br>
<br>
{
"version": "0.5.0",
"EmberENV": {
"FEATURES": {}
},
"options": {
"enable-testing": false
},
"dependencies": {
"jquery": "https://cdnjs.cloudflare.com/ajax/libs/jquery/1.11.3/jquery.js",
"ember": "1.13.11",
"ember-data": "https://cdnjs.cloudflare.com/ajax/libs/ember-data.js/2.2.0/ember-data.js",
"ember-template-compiler": "1.13.11"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment