method Uint16ArrayConstructor.from
Private
Uint16ArrayConstructor.from(arrayLike: ArrayLike<number>): Uint16Array

Creates an array from an array-like or iterable object.

Parameters

arrayLike: ArrayLike<number>

An array-like or iterable object to convert to an array.

Return Type

Uint16ArrayConstructor.from<T>(
arrayLike: ArrayLike<T>,
mapfn: (
v: T,
k: number,
) => number
,
thisArg?: any,
): Uint16Array

Creates an array from an array-like or iterable object.

Type Parameters

Parameters

arrayLike: ArrayLike<T>

An array-like or iterable object to convert to an array.

mapfn: (
v: T,
k: number,
) => number

A mapping function to call on every element of the array.

optional
thisArg: any

Value of 'this' used to invoke the mapfn.

Return Type