@conform-to/yup
Version:
Conform helpers for integrating with yup
12 lines • 675 B
TypeScript
import { type Intent, type Submission } from '@conform-to/dom';
import * as yup from 'yup';
export { getYupConstraint } from './constraint';
export declare function parseWithYup<Schema extends yup.AnyObjectSchema>(payload: FormData | URLSearchParams, config: {
schema: Schema | ((intent: Intent | null) => Schema);
async?: false;
}): Submission<yup.InferType<Schema>, string[]>;
export declare function parseWithYup<Schema extends yup.AnyObjectSchema>(payload: FormData | URLSearchParams, config: {
schema: Schema | ((intent: Intent | null) => Schema);
async: true;
}): Promise<Submission<yup.InferType<Schema>, string[]>>;
//# sourceMappingURL=index.d.ts.map