UNPKG

667 BTypeScriptView Raw
1import React from 'react';
2import type { FC, ReactNode } from 'react';
3import type { FormInstance } from 'rc-field-form';
4import type { NamePath } from 'rc-field-form/es/interface';
5declare type RenderChildren<Values = any> = (changedValues: Record<string, any>, form: FormInstance<Values>) => ReactNode;
6declare type ChildrenType<Values = any> = RenderChildren<Values>;
7export interface FormSubscribeProps {
8 to: NamePath[];
9 children: ChildrenType;
10}
11export declare const FormSubscribe: FC<FormSubscribeProps>;
12export declare const Watcher: React.NamedExoticComponent<{
13 form: FormInstance;
14 namePath: NamePath;
15 onChange: () => void;
16}>;
17export {};