@mui/toolpad-utils
Advanced tools
Comparing version 0.1.13 to 0.1.14
export type EventName = string | symbol; | ||
export type EventHandler<T = unknown> = (event: T) => void; | ||
export type AllEventsHandler<T extends Record<EventName, unknown>, K extends keyof T = keyof T> = (type: keyof T, event: T[K]) => void; | ||
/** | ||
@@ -11,2 +12,3 @@ * Lightweight event emitter | ||
*/ | ||
on(name: '*', handler: AllEventsHandler<T>): void; | ||
on<K extends keyof T>(name: K, handler: EventHandler<T[K]>): void; | ||
@@ -13,0 +15,0 @@ /** |
import { | ||
Emitter | ||
} from "./chunk-RUS6RU4B.js"; | ||
} from "./chunk-UL5SNADH.js"; | ||
export { | ||
Emitter | ||
}; |
import { | ||
Emitter | ||
} from "./chunk-RUS6RU4B.js"; | ||
} from "./chunk-UL5SNADH.js"; | ||
@@ -5,0 +5,0 @@ // src/react.tsx |
{ | ||
"name": "@mui/toolpad-utils", | ||
"version": "0.1.13", | ||
"version": "0.1.14", | ||
"description": "Build MUI apps quickly", | ||
@@ -55,3 +55,3 @@ "author": "MUI Toolpad team", | ||
}, | ||
"gitHead": "f616eae6eee0bd93750832125b26ac996d4b2cfe", | ||
"gitHead": "9dce9849d6206e511989f97994e20b3143fa927d", | ||
"dependencies": { | ||
@@ -61,4 +61,4 @@ "react-is": "18.2.0" | ||
"devDependencies": { | ||
"@types/react-is": "^18.2.0" | ||
"@types/react-is": "18.2.0" | ||
} | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
43862
1279