Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

scroll-animations

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

scroll-animations

Scroll animations for Smooth Scroll Bar

  • 1.1.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
6
Maintainers
1
Weekly downloads
 
Created
Source

SCROLL ANIMATION FOR SMOOTH SCROLLBAR

JavaScript plugin that implement AOS and Relax animations on scrolling with Smooth Scrollbar

DEPENDENCIES

HOW USE

  1. Download or git clone

    git clone https://github.com/BiserStoilov/scroll-animations.git
    
  2. Install dependencies

    npm install
    
  3. Run demo

    npm run demo
    
  4. Build production with dependencies

    npm run build
    
  5. Run plugin

    <body data-aos-easing="ease-in-out" data-aos-duration="1000" data-aos-delay="100">
        <div id="scroll-animation-content">
            <div data-type-animation="aos" data-aos="fade-up"></div>
            <div data-type-animation="parallax"></div>
            <div data-type-animation="parallax" data-parallax-speed="10"></div>
        </div>
    </body>
    
    import scrollAnimations from 'path/to/scroll-animations/src/index'; 
    const sa = scrollAnimations({
        element: '#scroll-animation-content'
    });
    
  6. Public methods

    // Get Smooth Scrollbar instance
    const smoothScrollBar = sa.getScrollBar();
    // Destroy
    sa.destroy();
    
  7. Smoot ScrollBar Methods

    const sa = scrollAnimations({
        element: '#scroll-animation-content'
    });
    const smoothScrollBar = sa.getScrollBar();
    const element = document.querySelector('#your-element');
    smoothScrollBar.addListener(() => {
        console.log(smoothScrollBar.isVisible(element));
    }); 
    

NPM

npm i scroll-animations

Keywords

FAQs

Package last updated on 02 Aug 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc