Skip to content

Instantly share code, notes, and snippets.

@e00dan
Created October 3, 2015 10:07
Show Gist options
  • Save e00dan/97bdd14f8ccef48bb0c5 to your computer and use it in GitHub Desktop.
Save e00dan/97bdd14f8ccef48bb0c5 to your computer and use it in GitHub Desktop.
New Twiddle
import Ember from 'ember';
export default Ember.Controller.extend({
actions: {
add(x, y) {
alert('this is done right '+x+ ' ' + y);
}
}
});
<br><h1>alpha template</h1>
<div>
<label>X value</label>
{{input value=xValue}}
<label>Y</label>
{{input value=yValue}}
<input type="button" id ="add-button" value="Add" {{action 'add' xValue yValue}}/>
</div>
{
"version": "0.4.11",
"dependencies": {
"jquery": "https://cdnjs.cloudflare.com/ajax/libs/jquery/1.11.3/jquery.js",
"ember": "https://cdnjs.cloudflare.com/ajax/libs/ember.js/1.13.9/ember.debug.js",
"ember-data": "https://cdnjs.cloudflare.com/ajax/libs/ember-data.js/1.13.11/ember-data.js",
"ember-template-compiler": "https://cdnjs.cloudflare.com/ajax/libs/ember.js/1.13.9/ember-template-compiler.js"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment