Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

x/entropy/mod.ts>Validator

The core module of Entropy framework for Deno.
Latest
class Validator
Re-export
import { Validator } from "https://deno.land/x/entropy@1.0.0-beta.17/mod.ts";

Constructors

new
Validator()

Properties

private
readonly
configurator
private
readonly
localizator
private
readonly
patterns: Record<string, RegExp>
private
readonly
rules: ValidatorRule[]

Methods

private
check(
fieldValue: FormDataEntryValue | string | null,
ruleValue: unknown,
fieldName: string,
): Promise<boolean>
validate(
subject: HttpRequest | Record<string, string | null | undefined>,
rules: Record<string, Partial<ValidatorRulesList> | Record<string, unknown>>,
errorLocale?: string,
): Promise<Record<string, string[]>>