Skip to content

Instantly share code, notes, and snippets.

View jenweber's full-sized avatar

Jen Weber jenweber

View GitHub Profile
@jenweber
jenweber / controllers.application.js
Last active December 19, 2016 09:53 — forked from gokatz/controllers.application.js
qp from controller
import Ember from 'ember';
export default Ember.Controller.extend({
appName: 'Ember Twiddle'
});
@jenweber
jenweber / components.my-component.js
Last active February 2, 2017 01:17
Weird onchange behavior
import Ember from 'ember';
export default Ember.Component.extend({
actions: {
somethingChangedComponent: function() {
console.log('something changed Component')
}
}
});
@jenweber
jenweber / components.compass-component.js
Last active March 29, 2017 18:21
SVG animation and interaction
import Ember from 'ember';
export default Ember.Component.extend({
currentOrientation: 0,
});
import Ember from 'ember';
export default Ember.Controller.extend({
appName: 'Readonly Nested Data'
});
import Ember from 'ember';
export default Ember.Component.extend({
animateBool: true,
actions: {
applyAnimation() {
this.toggleProperty('animateBool')
}
}
});
@jenweber
jenweber / components.my-component.js
Last active May 25, 2017 23:04
Non-working closure actions
import Ember from 'ember';
export default Ember.Component.extend({
});
import Ember from 'ember';
export default Ember.Component.extend({
actions: {
someAction(target) {
console.log('target', target)
}
}
});
import Ember from 'ember';
export default Ember.Controller.extend({
appName: 'Ember Twiddle'
});
@jenweber
jenweber / controllers.application.js
Created August 12, 2017 14:26
Minimal CRUD Example with Ember Data
import Ember from 'ember';
export default Ember.Controller.extend({
appName: 'Ember Minimal CRUD'
});
@jenweber
jenweber / application.hbs
Last active August 12, 2017 21:41
Minimal CRUD with Ember Data
<div>
Read all:
<ul>
{{#each model as |game|}}
<li>{{game.title}}, id {{game.id}}</li>
{{/each}}
</ul>
</div>
<div>