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

x/valibot/src/schemas/tuple/tuple.ts>tuple

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

Creates a tuple schema.

Type Parameters

TTupleItems extends TupleShape
optional
TTupleRest extends BaseSchema | undefined = undefined

Parameters

The items schema.

A validation and transformation pipe.

Creates a tuple schema.

Type Parameters

TTupleItems extends TupleShape
optional
TTupleRest extends BaseSchema | undefined = undefined

Parameters

The items schema.

optional
error: string

The error message.

A validation and transformation pipe.

Creates a tuple schema.

Type Parameters

TTupleItems extends TupleShape
optional
TTupleRest extends BaseSchema | undefined = undefined

Parameters

The items schema.

The rest schema.

A validation and transformation pipe.

Creates a tuple schema.

Type Parameters

TTupleItems extends TupleShape
optional
TTupleRest extends BaseSchema | undefined = undefined

Parameters

The items schema.

The rest schema.

optional
error: string

The error message.

A validation and transformation pipe.