Skip to content

Instantly share code, notes, and snippets.

Avatar

Michael Underwood mikeu

  • Calgary, Alberta, Canada
View GitHub Profile
View vue-js-data-reactivity.js
import Vue from 'vue'
import {DataStore, Record} from 'js-data'
// Define a base class that enables property-level vue reactivity and, optionally does so at the relationship-level.
export class VueReactiveRecord extends Record {
constructor (...args) {
// Among other things, this will apply js-data schema if configured to do so; be sure to do `track: true`.
super(...args);
@mikeu
mikeu / controllers.application.js
Last active Oct 18, 2017
Pagination Links demo changing last page
View controllers.application.js
import Ember from 'ember';
export default Ember.Controller.extend({
currentPage: 1,
filteredLastPage: 8,
actions: {
@mikeu
mikeu / controllers.application.js
Last active Oct 5, 2017
ember-changeset-validations custom relative validation
View controllers.application.js
import Ember from 'ember';
import validateLessThan from '../validators/validateLessThanAttr';
export default Ember.Controller.extend({
pairValidations: {
smaller: validateLessThan('larger'),
},
});
@mikeu
mikeu / controllers.application.js
Last active May 11, 2017 — forked from samselikoff/controllers.application.js
Mirage 0.3 - Many to Many, with factories
View controllers.application.js
import Ember from 'ember';
export default Ember.Controller.extend({
db: Ember.computed('refreshDb', function() {
let dump = window.server.schema.db.dump();
return JSON.stringify(dump, null, 2);
}),
View gist:a76fb3a2a616095cee30
Verifying that +munderwood is my blockchain ID. https://onename.com/munderwood
View keybase.md

Keybase proof

I hereby claim:

  • I am mikeu on github.
  • I am munderwood (https://keybase.io/munderwood) on keybase.
  • I have a public key whose fingerprint is 93C8 B029 6CA7 0968 E578 58CF 1456 6BA0 185F B753

To claim this, I am signing this object: