Skip to main content
Module

x/valibot/mod.ts>literalAsync

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

Creates an async literal schema.

Type Parameters

TLiteral extends Literal

Parameters

literal: TLiteral

The literal value.

optional
message: ErrorMessage = [UNSUPPORTED]

The error message.

Returns

LiteralSchemaAsync<TLiteral>

An async literal schema.