Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/valibot/src/actions/index.ts>minLength

The modular and type safe schema library for validating structural data 🤖
Extremely Popular
Latest
function minLength
import { minLength } from "https://deno.land/x/valibot@v1.0.0-beta.2-to-json-schema/src/actions/index.ts";

Creates a min length validation action.

Type Parameters

TInput extends LengthInput
TRequirement extends number

Parameters

requirement: TRequirement

The minimum length.

Returns

A min length action.

Creates a min length validation action.

Type Parameters

TInput extends LengthInput
TRequirement extends number
TMessage extends ErrorMessage<MinLengthIssue<TInput, TRequirement>> | undefined

Parameters

requirement: TRequirement

The minimum length.

message: TMessage

The error message.