UNPKG

@sanity/form-builder

Version:
11 lines 439 B
import { SchemaType, RuleSpec } from '@sanity/types'; /** * Finds the first matching validation rule spec from a Rule class instance. * * @internal * Note: This accesses private fields of the rule. */ export declare function getValidationRule<RuleFlag extends RuleSpec['flag']>(type: SchemaType | null | undefined, ruleName: RuleFlag): Extract<RuleSpec, { flag: RuleFlag; }> | null; //# sourceMappingURL=getValidationRule.d.ts.map