7
backbone.jsにコレクションメソッドをチェーンする方法はありますか?Chain Backbone.jsコレクションメソッド
var Collection = this.collection;
Collection = Collection.where({county: selected});
Collection = Collection.groupBy(function(city) {
return city.get('city')
});
Collection.each(function(city) {
// each items
});
私はこのような何かを試してみましたが、それは間違っている:
Object[object Object],[object Object],[object Object] has no method 'groupBy'