UNPKG

beautiful-react-hooks

Version:

A collection of beautiful (and hopefully useful) React hooks to speed-up your components and hooks development

12 lines (11 loc) 502 B
"use strict"; var __importDefault = (this && this.__importDefault) || function (mod) { return (mod && mod.__esModule) ? mod : { "default": mod }; }; Object.defineProperty(exports, "__esModule", { value: true }); var useGlobalEvent_1 = __importDefault(require("./useGlobalEvent")); /** * Returns a function that accepts a callback to be performed when the window scrolls. */ var useWindowScroll = function () { return (0, useGlobalEvent_1.default)('scroll'); }; exports.default = useWindowScroll;