Start sharing components as a team!Share components as a team!Join Bit to build your applications faster.Get Started Free

initial

v4.17.11arrow_drop_down
v4.17.11
STATUS
Passing
DOWNLOADS
40
LICENSE
MIT
VISIBILITY
Public
PUBLISHED
10 months ago
SIZE
630 B
Gets all but the last element of `array`.
1 contributor
Use initial in your project ?
Copied
npm i @bit/lodash.lodash.initial
Set Bit as a scoped registryLearn more
npm config set '@bit:registry' https://node.bit.dev
Component Example
React
React
Vue
Angular
React Native
Add dependency... help_outline
Just
import
any of the 1 million components
and packages in Bit or NPM to the example.
import Button from '@bit/grommet.grommet.button';
import Lodash from 'lodash';
toggle layout
modifieddraft
chevron_left
chevron_right
initial (
array:Array
) : Array

Gets all but the last element of array.

Example
_.initial([1, 2, 3]);
// => [1, 2]
Argument
array: Array

The array to query.

Returns
Array

Returns the slice of `array`.