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

scroll-behaviour

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-behaviour

Scroll Behavior polyfill http://iamdustan.com/smoothscroll for universal use.

  • 0.3.4
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
749
increased by35.44%
Maintainers
1
Weekly downloads
 
Created
Source

Scroll Behaviour

This is a paper thin wrapper around the existing https://github.com/iamdustan/smoothscroll polyfill.

It allows for importing in nodejs (which does nothing), and automatically calls smoothscroll.polyfill() in the browser to make things simpler.

Installation

Npm
npm install scroll-behaviour

Example Manual

// commonjs
require('scroll-behaviour').polyfill()

// es6
import { polyfill } 'scroll-behaviour'
polyfill()

Example Automatic

Automatically call .polyfill()

// commonjs
require('scroll-behaviour/polyfill')

// es6
import 'scroll-behaviour/polyfill'

Browser Support

Successfully tested in:

  • Safari 6+
  • iOS Safari 6+
  • Chrome (last version)
  • natively supported in Firefox
  • Internet Explorer 9+
  • Microsoft Edge
  • Opera Next

If you have tested this and worked as expected in a different browser let us know so we can add it to the list, if not open an issue providing browser, browser version and a good description about it.

Standards Documentation

Keywords

FAQs

Package last updated on 18 Apr 2017

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