Need Paper Mache

    srraf

    3.2.1 • Public • Published

    srraf

    Monitor scrolling and resizing without event listeners. 300 bytes gzipped.

    Install

    npm i srraf --save

    Usage

    import srraf from 'srraf'
     
    const scroller = srraf(({ x, px, y, py, vh, pvh, vw, pvw }, timestamp) => {
      // ...
    })
     
    scroller.update() // check position
    scroller.destroy() // destroy listener

    Note: values prefixed with p denote previous values.

    License

    MIT License © Eric Bailey

    Keywords

    none

    Install

    npm i srraf

    DownloadsWeekly Downloads

    93

    Version

    3.2.1

    License

    MIT

    Unpacked Size

    9.43 kB

    Total Files

    8

    Last publish

    Collaborators

    • estrattonbailey