• Places the elements in the array argument first in the original array and returns a new array.

    Type Parameters

    • T

    Parameters

    • original: T[]

      The original array

    • elements: T[]

      The array to concatenate

    Returns T[]

    A new array with elementN array inserted at the beginning of the original array.

    Example

    <pre>
    const original = ["a", "b"];
    const result = ["a", "b", "c", "d"];
    expect(concat(original, ["c", "d"])).to.eql(result);
    </pre>

Generated using TypeDoc