scroll-to-y

1.0.1 • Public • Published

Scroll to y

var scrollToY = require('scroll-to-y');

// scrollToY(scrollTargetY, speed, easing);
// 
// scrollTargetY: the target scrollY property of the window
// speed: time in pixels per second
// easing: easing equation to use

scrollToY(0, 1500, 'easeInOutQuint');

Easing Equations

  • easeOutSine
  • easeInOutSine
  • easeInOutQuint

/scroll-to-y/

    Package Sidebar

    Install

    npm i scroll-to-y

    Weekly Downloads

    12

    Version

    1.0.1

    License

    MIT

    Last publish

    Collaborators

    • jbraithwaite