API reference: @salmonui/data-grid/engine
CustomValidatortype
import type { CustomValidator } from '@salmonui/data-grid/engine';Also exported from @salmonui/data-grid/engine/validation.
type CustomValidator<Row = unknown, Ctx = ValidatorContext<Row>> = (value: unknown, row: Row, ctx: Ctx) => string | boolean | null | undefined | PromiseLike<string | boolean | null | undefined>;
Custom validator: returns an error message, or null / undefined / true when the value is valid (false uses the rule message). May return a promise (async validation): commit waits for it.