adopted-ember-addons / ember-moment

MIT License
400 stars 122 forks source link

Feature request: moment transform #276

Open jamesarosen opened 6 years ago

jamesarosen commented 6 years ago

It'd be lovely to have an ember-data transform so I can make all model date fields moments:

export default DS.Model.extend({
  createdAt: DS.attr('moment'),
  name: DS.attr('string'),
  updatedAt: DS.attr('moment'),
})
jasonmit commented 6 years ago

@jamesarosen this was asked for in the past. @stefanpenner was against it because of the perf impact.

Context: https://github.com/stefanpenner/ember-moment/issues/157#issuecomment-217732169