Skip to main content
The Deno 2 Release Candidate is here
Learn more
Module

x/hono/middleware/validator/validator.ts>VBase

Ultrafast web framework for Cloudflare Workers, Deno, and Bun. Fast, but not only fast.
Very Popular
Go to Latest
class VBase
Abstract
import { VBase } from "https://deno.land/x/hono@v2.2.0/middleware/validator/validator.ts";

Constructors

new
VBase(options: VOptions)

Properties

private
_message: string | undefined
private
validateValue: (value: Type) => boolean
addRule: (rule: Rule) => unknown
addSanitizer: (sanitizer: Sanitizer) => unknown
asBoolean: () => unknown
asNumber: () => unknown
asObject: () => unknown
isEqual: (comparison: unknown) => unknown
isOptional: () => unknown
isRequired: () => unknown
key: string
rules: Rule[]
sanitizers: Sanitizer[]
target: Target
type:
| "string"
| "number"
| "boolean"
| "object"
validate: (req: Request) => Promise<ValidateResult>

Methods

message(value: string)