Skip to content
bredele edited this page Feb 11, 2014 · 8 revisions
  1. Class Store

Class Store

The Store component is the model layer of your application. It's basically a wrapper for your models and collections that contains your data and all the logic surrounding it such as formatters, access control, computed properties, reset, local storage and can be easily extended with its middleware engine.

var Store = require('maple/store');

var model = new Store({
  name: 'olivier'
});

var collection = new Store([{
  name: 'olivier'
}, {
  name: 'amy'
}
]);

Store is really simple and reduces the complexity of your application, see article.

Store inherits from [Emitter](https://github.com/leafs/maple/wiki/Emitter and allows you to listen changes in your data.

Methods

Clone this wiki locally