UNPKG

@progress/kendo-react-common

Version:

React Common package delivers common utilities that can be used with the KendoReact UI components. KendoReact Common Utilities package

19 lines (18 loc) 718 B
/**----------------------------------------------------------------------------------------- * Copyright © 2023 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *-------------------------------------------------------------------------------------------*/ /** @hidden */ export declare enum COLLECTION_ACTION { add = 0, remove = 1 } /** @hidden */ export type Collection<T> = T[]; /** @hidden */ export interface CollectionAction<T> { type: COLLECTION_ACTION; item: T; } /** @hidden */ export declare const useCollection: <T extends unknown>(initial?: T[]) => [T[], (event: CollectionAction<T>) => void];