mirror of
https://github.com/Nezumi-2711/react-training.git
synced 2026-09-22 13:38:51 +00:00
Change type name
This commit is contained in:
@@ -28,13 +28,13 @@ const getPropValues = (stateSchema: TStateSchema, prop?: TPropValues) => {
|
||||
}, {} as TKeyValue);
|
||||
};
|
||||
|
||||
type test = {
|
||||
type TValidator = {
|
||||
validatorFunc: (value: string) => boolean;
|
||||
prop: string;
|
||||
required?: boolean;
|
||||
};
|
||||
|
||||
const addValidator = ({ validatorFunc, prop, required = true }: test) => {
|
||||
const addValidator = ({ validatorFunc, prop, required = true }: TValidator) => {
|
||||
return {
|
||||
required: required,
|
||||
validator: {
|
||||
|
||||
Reference in New Issue
Block a user