Skip to content

QxGH/smooth-scrollbar

Repository files navigation

Smooth Scrollbar

Customizable, Flexible, and High Performance Scrollbars!

npm downloads core size gzip size Build status license

Sponsor

Installation

⚠️ DO NOT use custom scrollbars unless you know what you are doing. Read more

Via NPM (recommended):

npm install smooth-scrollbar --save

Via Bower:

bower install smooth-scrollbar --save

Browser Compatibility

Browser Version
IE 10+
Chrome 22+
Firefox 16+
Safari 8+
Android Browser 4+
Chrome for Android 32+
iOS Safari 7+

Demo

https://idiotwu.github.io/smooth-scrollbar/

Usage

Since this package has a pkg.module field, it's highly recommended to import it as an ES6 module with some bundlers like webpack or rollup:

import Scrollbar from 'smooth-scrollbar';

Scrollbar.init(document.querySelector('#my-scrollbar'));

If you are not using any bundlers, you can just load the UMD bundle:

<script src="dist/smooth-scrollbar.js"></script>

<script>
  var Scrollbar = window.Scrollbar;

  Scrollbar.init(document.querySelector('#my-scrollbar'));
</script>

Documentation

latest 7.x

Who's Using It

  • conference.awwwards.com: Awwwards Conference - An Event for UX / UI Designers and Web Developers.
  • lp.anzi.kr: Listeners Playlist.
  • Feel free to add yours here 🤗.

License

MIT

About

Customizable, Pluginable, and High Performance Scrollbars!

Resources

License

Code of conduct

Stars

Watchers

Forks

Packages

No packages published

Languages

  • TypeScript 73.5%
  • HTML 12.2%
  • JavaScript 9.4%
  • CSS 3.6%
  • Shell 1.3%