Added slice to Backbone.Collection

Without it, TypeScript throws a type error, stating that `Collection<TModel>` does not have a method called `slice`.
This commit is contained in:
Salehen Shovon Rahman
2015-07-21 15:09:23 -07:00
parent 8f51d25ad3
commit 8b706fb1c6

View File

@@ -247,6 +247,7 @@ declare module Backbone {
select(iterator: any, context?: any): any[];
size(): number;
shuffle(): any[];
slice(min: number, max?: number): TModel[];
some(iterator: (element: TModel, index: number) => boolean, context?: any): boolean;
sortBy(iterator: (element: TModel, index: number) => number, context?: any): TModel[];
sortBy(attribute: string, context?: any): TModel[];