import { Validator } from "../Validator" ; import { FieldValidator } from "./FieldValidator" ; import { extractValidatorPropeties } from "./utils" ; @ Validator ( ) export class FnValidator implements FieldValidator { validate ( field , props , value ) { if ( typeof props == "function" ) { return props ( value ) ; } } }