Share your code. Components are building blocks, you are the architect.

utils/insert-all
v1.1.0
1.1.0
MIT
PUBLIC
3
1     DEPENDENCIES
Build: fail
BuildFail
Build Status: fail
Inserts the sub-list into the list, at the specified `index`

Please configure Bit as a scoped registry to install components with NPM.Learn more

npm config set '@bit:registry' https://node.bitsrc.io
Use utils/insert-all in your project
npm i @bit/bit.ramda.utils.insert-all
Copied

insertAll (index:Number, elts:Array, list:Array) : Array

Inserts the sub-list into the list, at the specified index. Note that this is not destructive: it returns a copy of the list with the changes. <small>No lists have been harmed in the application of this function.</small>

Example

R.insertAll(2, ['x','y','z'], [1,2,3,4]); //=> [1,2,'x','y','z',3,4]

Arguments

index: Number

The position to insert the sub-list

elts: Array

The sub-list to insert into the Array

list: Array

The list to insert the sub-list into

Returns

Array

A new Array with `elts` inserted starting at `index`.