Gathering detailed insights and metrics for react-custom-scrollbars
Gathering detailed insights and metrics for react-custom-scrollbars
Gathering detailed insights and metrics for react-custom-scrollbars
Gathering detailed insights and metrics for react-custom-scrollbars
npm install react-custom-scrollbars
Typescript
Module System
Node Version
NPM Version
94.4
Supply Chain
95
Quality
74.5
Maintenance
100
Vulnerability
100
License
JavaScript (100%)
Total Downloads
52,225,896
Last Day
4,896
Last Week
136,829
Last Month
587,354
Last Year
7,213,156
MIT License
3,220 Stars
266 Commits
575 Forks
29 Watchers
26 Branches
20 Contributors
Updated on Jul 01, 2025
Minified
Minified + Gzipped
Latest Version
4.2.1
Package Id
react-custom-scrollbars@4.2.1
Size
83.99 kB
NPM Version
4.1.2
Node Version
7.7.1
Published on
Oct 28, 2017
Cumulative downloads
Total Downloads
Last Day
-1.6%
4,896
Compared to previous day
Last Week
-2%
136,829
Compared to previous week
Last Month
-4.7%
587,354
Compared to previous month
Last Year
-11%
7,213,156
Compared to previous year
3
34
requestAnimationFrame
for 60fps1npm install react-custom-scrollbars --save
This assumes that you’re using npm package manager with a module bundler like Webpack or Browserify to consume CommonJS modules.
If you don’t yet use npm or a modern module bundler, and would rather prefer a single-file UMD build that makes ReactCustomScrollbars
available as a global object, you can grab a pre-built version from unpkg. We don’t recommend this approach for any serious application, as most of the libraries complementary to react-custom-scrollbars
are only available on npm.
This is the minimal configuration. Check out the Documentation for advanced usage.
1import { Scrollbars } from 'react-custom-scrollbars'; 2 3class App extends Component { 4 render() { 5 return ( 6 <Scrollbars style={{ width: 500, height: 300 }}> 7 <p>Some great content...</p> 8 </Scrollbars> 9 ); 10 } 11}
The <Scrollbars>
component is completely customizable. Check out the following code:
1import { Scrollbars } from 'react-custom-scrollbars'; 2 3class CustomScrollbars extends Component { 4 render() { 5 return ( 6 <Scrollbars 7 onScroll={this.handleScroll} 8 onScrollFrame={this.handleScrollFrame} 9 onScrollStart={this.handleScrollStart} 10 onScrollStop={this.handleScrollStop} 11 onUpdate={this.handleUpdate} 12 renderView={this.renderView} 13 renderTrackHorizontal={this.renderTrackHorizontal} 14 renderTrackVertical={this.renderTrackVertical} 15 renderThumbHorizontal={this.renderThumbHorizontal} 16 renderThumbVertical={this.renderThumbVertical} 17 autoHide 18 autoHideTimeout={1000} 19 autoHideDuration={200} 20 autoHeight 21 autoHeightMin={0} 22 autoHeightMax={200} 23 thumbMinSize={30} 24 universal={true} 25 {...this.props}> 26 ); 27 } 28}
All properties are documented in the API docs
Run the simple example:
1# Make sure that you've installed the dependencies 2npm install 3# Move to example directory 4cd react-custom-scrollbars/examples/simple 5npm install 6npm start
1# Make sure that you've installed the dependencies 2npm install 3# Run tests 4npm test
1# Run code coverage. Results can be found in `./coverage` 2npm run test:cov
MIT
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
license file detected
Details
Reason
Found 8/22 approved changesets -- score normalized to 3
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
Reason
139 existing vulnerabilities detected
Details
Score
Last Scanned on 2025-06-23
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More