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

x/valibot/src/schemas/instance/instanceAsync.ts>instanceAsync

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

Creates an async instance schema.

Type Parameters

TClass extends Class

Parameters

class_: TClass

The class of the instance.

optional
pipe: PipeAsync<InstanceType<TClass>>

A validation and transformation pipe.

Returns

An async instance schema.

Creates an async instance schema.

Type Parameters

TClass extends Class

Parameters

class_: TClass

The class of the instance.

optional
message: ErrorMessage

The error message.

optional
pipe: PipeAsync<InstanceType<TClass>>

A validation and transformation pipe.

Returns

An async instance schema.