UNPKG

@openhands/ui

Version:
12 lines (11 loc) 424 B
type ArrayActions<T> = { push: (value: T | T[]) => void; replace: (value: T | T[]) => void; addAtIndex: (index: number, value: T) => void; removeAt: (index: number) => void; remove: (value: T, compareBy?: keyof T) => void; subset: (indexStart: number, indexEnd: number) => void; clear: () => void; }; export declare function useArray<T>(initialValue: T | T[]): [T[], ArrayActions<T>]; export {};