source: imaps-frontend/node_modules/react-use/esm/useMethods.d.ts@ 0c6b92a

main
Last change on this file since 0c6b92a was d565449, checked in by stefan toskovski <stefantoska84@…>, 3 months ago

Update repo after prototype presentation

  • Property mode set to 100644
File size: 321 bytes
RevLine 
[d565449]1declare type CreateMethods<M, T> = (state: T) => {
2 [P in keyof M]: (payload?: any) => T;
3};
4declare type WrappedMethods<M> = {
5 [P in keyof M]: (...payload: any) => void;
6};
7declare const useMethods: <M, T>(createMethods: CreateMethods<M, T>, initialState: T) => [T, WrappedMethods<M>];
8export default useMethods;
Note: See TracBrowser for help on using the repository browser.