construct()

Constructs an object with an arbitrary number of arguments passed via an array (or an array-like object).

This function is valid in v2.1.0 to v2.7.0. This function has been downloaded 0 times.

Parameters

{Function} constructor
The constructor function.
{…*=} args Optional
Zero or more arguments with which constructor will be used to construct the desired object type.

Returns

{*}
Returns the result of calling new constructor(...args).

Required Function

This function requires the following function which is included automatically:

  • slice()
    Slice does not modify the original array, but instead returns a shallow copy of elements from the original array.