"use client";
import { useEffect, useEffectEvent } from "react";
//#region packages/@mantine/hooks/src/use-window-event/use-window-event.ts
function useWindowEvent(type, listener, options) {
	const stableListener = useEffectEvent(listener);
	useEffect(() => {
		window.addEventListener(type, stableListener, options);
		return () => window.removeEventListener(type, stableListener, options);
	}, [type]);
}
//#endregion
export { useWindowEvent };

//# sourceMappingURL=use-window-event.mjs.map