@shopify/react-form-state
Version:
Manage react forms tersely and type-safe with no magic.
8 lines (7 loc) • 515 B
TypeScript
import isEqual from 'fast-deep-equal';
export { isEqual };
export declare function mapObject<Input, Output>(input: Input, mapper: (value: any, key: keyof Input) => any): Output;
export declare function push<T>(array: T[], ...values: T[]): T[];
export declare function remove<T>(array: T[], targetIndex: number): T[];
export declare function replace<T>(array: T[], targetIndex: number, newValue: T): T[];
export declare function set<InputType extends Object>(rootObject: InputType, path: string[], value: any): any;