4b30ee02 by Adam Heath

Start of iterate() rivets api method.

1 parent c4e53ec5
...@@ -57,6 +57,13 @@ define(function(require) { ...@@ -57,6 +57,13 @@ define(function(require) {
57 } 57 }
58 } 58 }
59 }, 59 },
60 iterate: function iterate(obj, callback, context) {
61 if (obj instanceof Model) {
62 debugger;
63 } else if (obj instanceof Collection) {
64 obj.each(callback, context);
65 }
66 },
60 }; 67 };
61 })(Backbone.Model, Backbone.Collection, 'add remove reset sort'); 68 })(Backbone.Model, Backbone.Collection, 'add remove reset sort');
62 return adapter; 69 return adapter;
......