import { Rule } from '../../../component/Rule/type'; interface UseValidateProps { rules: Rule[]; onError?(error: Error): void; } declare function useValidate(props: UseValidateProps): { validate: (value: any, data?: any) => Promise; error: any; }; export default useValidate;