UNPKG

403 BTypeScriptView Raw
1import { Struct, StructResult, StructFailure, StructContext } from './struct';
2export declare type StructRecord<T> = Record<string, Struct<T>>;
3export declare type StructTuple<T> = {
4 [K in keyof T]: Struct<T[K]>;
5};
6/**
7 * Convert a validation result to an iterable of failures.
8 */
9export declare function toFailures(result: StructResult, context: StructContext): Iterable<StructFailure>;