Skip to content

Function.IsArray 1

github-actions[bot] edited this page Jun 29, 2026 · 20 revisions

umt / IsArray

Function: IsArray()

IsArray(target, propertyKey): void

Defined in: Decorator/IsArray.ts:18

Property decorator that requires the decorated field to hold an array. The rule is consumed by validateInstance and Validatable.

Parameters

target

object

The class prototype.

propertyKey

string | symbol

The decorated field.

Returns

void

Example

class Cart {
  @IsArray items = [];
}

API

Classes

Interfaces

Type Aliases

Variables

Functions

Clone this wiki locally