UNPKG

@blinkk/selective-edit

Version:
14 lines (13 loc) 468 B
import { AllowExcludeRuleConfig, Rule, RuleConfig } from '../validationRules'; export interface MatchRuleConfig extends RuleConfig { allowed?: AllowExcludeRuleConfig; excluded?: AllowExcludeRuleConfig; } export declare class MatchRule extends Rule { config: MatchRuleConfig; defaultMessage: string; patternCache: Record<string, RegExp>; constructor(config: MatchRuleConfig); private cachePattern; validate(value: any): string | null; }