diff --git a/lodash/lodash-tests.ts b/lodash/lodash-tests.ts index 7ff608f52b..e342cb7c83 100644 --- a/lodash/lodash-tests.ts +++ b/lodash/lodash-tests.ts @@ -1283,31 +1283,31 @@ module TestRemove { } } -// _.rest -module TestRest { +// _.tail +module TestTail { let array: TResult[]; let list: _.List; { let result: TResult[]; - result = _.rest(array); - result = _.rest(list); + result = _.tail(array); + result = _.tail(list); } { let result: _.LoDashImplicitArrayWrapper; - result = _(array).rest(); - result = _(list).rest(); + result = _(array).tail(); + result = _(list).tail(); } { let result: _.LoDashExplicitArrayWrapper; - result = _(array).chain().rest(); - result = _(list).chain().rest(); + result = _(array).chain().tail(); + result = _(list).chain().tail(); } } diff --git a/lodash/lodash.d.ts b/lodash/lodash.d.ts index 49fba82c33..fabea5b907 100644 --- a/lodash/lodash.d.ts +++ b/lodash/lodash.d.ts @@ -22,7 +22,7 @@ TODO: - [x] Renamed _.overArgs to _.overArgs - [x] Renamed _.padLeft & _.padRight to _.padStart & _.padEnd - [x] Renamed _.pairs to _.toPairs -- [ ] Renamed _.rest to _.tail +- [x] Renamed _.rest to _.tail - [ ] Renamed _.restParam to _.rest - [ ] Renamed _.sortByOrder to _.orderBy - [ ] Renamed _.trimLeft & _.trimRight to _.trimStart & _.trimEnd @@ -1977,7 +1977,7 @@ declare module _ { ): LoDashExplicitArrayWrapper; } - //_.rest + //_.tail interface LoDashStatic { /** * Gets all but the first element of array. @@ -1987,35 +1987,35 @@ declare module _ { * @param array The array to query. * @return Returns the slice of array. */ - rest(array: List): T[]; + tail(array: List): T[]; } interface LoDashImplicitArrayWrapper { /** - * @see _.rest + * @see _.tail */ - rest(): LoDashImplicitArrayWrapper; + tail(): LoDashImplicitArrayWrapper; } interface LoDashImplicitObjectWrapper { /** - * @see _.rest + * @see _.tail */ - rest(): LoDashImplicitArrayWrapper; + tail(): LoDashImplicitArrayWrapper; } interface LoDashExplicitArrayWrapper { /** - * @see _.rest + * @see _.tail */ - rest(): LoDashExplicitArrayWrapper; + tail(): LoDashExplicitArrayWrapper; } interface LoDashExplicitObjectWrapper { /** - * @see _.rest + * @see _.tail */ - rest(): LoDashExplicitArrayWrapper; + tail(): LoDashExplicitArrayWrapper; } //_.slice