Skip to content

Instantly share code, notes, and snippets.

Colton J. Provias ColtonProvias

Block or report user

Report or block ColtonProvias

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@pixelhandler
pixelhandler / transforms.js
Last active Oct 3, 2016
Raw object and array tranforms for Ember Data
View transforms.js
/*
DS.attr('object')
*/
App.ObjectTransform = DS.Transform.extend({
deserialize: function(value) {
if (!$.isPlainObject(value)) {
return {};
} else {
return value;
}
@NuckChorris
NuckChorris / array.js
Last active Feb 12, 2018 — forked from pixelhandler/transforms.js
In Ember-CLI, transforms are located in app/transforms/name.js
View array.js
// app/transforms/array.js
import Ember from 'ember';
import DS from 'ember-data';
export default DS.Transform.extend({
deserialize: function(value) {
if (Ember.isArray(value)) {
return Ember.A(value);
} else {
return Ember.A();
You can’t perform that action at this time.