Skip to main content
Module

x/leaves/mod.ts>validator.arrayMaxSize

A Web framework For Deno with Decorator and middleware
Latest
function validator.arrayMaxSize
import { validator } from "https://deno.land/x/leaves@v0.1.5/mod.ts";
const { arrayMaxSize } = validator;

Checks if array's length is as maximal this number. If null or undefined is given then this function returns false.

Parameters

array: unknown
max: number

Returns

boolean