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

x/valibot/src/index.ts>includes

The modular and type safe schema library for validating structural data 🤖
Extremely Popular
Go to Latest
function includes
import { includes } from "https://deno.land/x/valibot@v0.35.0/src/index.ts";

Creates an includes validation action.

Type Parameters

TInput extends ContentInput
TRequirement extends ContentRequirement<TInput>

Parameters

requirement: TRequirement

The content to be included.

Returns

An includes action.

Creates an includes validation action.

Type Parameters

TInput extends ContentInput
TRequirement extends ContentRequirement<TInput>
TMessage extends ErrorMessage<IncludesIssue<TInput, TRequirement>> | undefined

Parameters

requirement: TRequirement

The content to be included.

message: TMessage

The error message.