var Obstruct = require('obstruct');
var minivents = require('minivents');
var createGetter = require('./lib/createGet');
var createSetter = require('./lib/createSet');
var merge = require('./lib/merge');
var noop = function () {};

var Model = Obstruct.extend({
  constructor: function (data) {
    minivents(this);
    data = merge({}, this.defaults, data || {});
    var _attr = {};
    for (var prop in data) {
      if (data.hasOwnProperty(prop)) {
        _attr[prop] = data[prop];
        Object.defineProperty(this, prop, {
          get: createGetter(_attr, prop),
          set: createSetter(_attr, prop, this)
        });
      }
    }
    this.init(data);
  },
  init: noop,
  defaults: {}
});

module.exports = Model;

@@ -665,16 +665,238 @@
 );%0A  %7D,%0A
+  data: function () %7B%0A    var data = %7B%7D;%0A    for (var prop in this) %7B%0A      if (this.hasOwnProperty(prop)) %7B%0A        if (typeof this%5Bprop%5D !== 'function') %7B%0A          data%5Bprop%5D = this%5Bprop%5D;%0A        %7D %0A      %7D%0A    %7D%0A  %7D,%0A
   init: 

Add data method to model