Naphthalene Possum Management

    @zcorky/throttle
    TypeScript icon, indicating that this package has built-in type declarations

    1.0.0 • Public • Published

    throttle

    NPM version Coverage Status Dependencies Build Status license issues

    Throttle a function.

    Install

    $ npm install @zcorky/throttle
    

    Usage

    // import
    import throttle from '@zcorky/throttle';
    
    // throttle
    function resize(e) {
      console.log('width', window.innerWidth);
      console.log('height', window.innerHeight);
    }
    
    window.onresize = throttle(resize, 200);

    Relatived

    Keywords

    none

    Install

    npm i @zcorky/throttle

    DownloadsWeekly Downloads

    576

    Version

    1.0.0

    License

    MIT

    Unpacked Size

    4.27 kB

    Total Files

    5

    Last publish

    Collaborators

    • uniquecolesmith