insertInto()

Inserts a value into an array at the given position.

This function is valid in v2.14.0 to v2.24.3. This function has been downloaded 61 times.

Parameters

{*} value
Value to insert into array.
{Array} array
Array into which a value will be inserted.
{number} position
Position at which to insert the value within array. A negative value will mean that the position is counted from the end of array. A position of -0 means that value will be added to the end of array.

Returns

{*}
A reference to value. This is useful when chaining.

Required Function

This function directly requires the following function which is included automatically:

  • insert()
    Inserts a value into an array at the given position.

Requiring Function

This function is directly required by the following function:

  • insert()
    Inserts a value into an array at the given position.