Skips the last N elements of an array.
const values = ['a', 'b', 'c', 'd'];const withoutLastTwo = Arr.skipLast(values, 2);const withoutLastThree = Arr.skipLast(3)(values);assert.deepStrictEqual(withoutLastTwo, ['a', 'b']);assert.deepStrictEqual(withoutLastThree, ['a']); Copy
const values = ['a', 'b', 'c', 'd'];const withoutLastTwo = Arr.skipLast(values, 2);const withoutLastThree = Arr.skipLast(3)(values);assert.deepStrictEqual(withoutLastTwo, ['a', 'b']);assert.deepStrictEqual(withoutLastThree, ['a']);
Skips the last N elements of an array.