Gathering detailed insights and metrics for re-use-debounce
Gathering detailed insights and metrics for re-use-debounce
npm install re-use-debounce
Typescript
Module System
64.6
Supply Chain
93.5
Quality
74.8
Maintenance
100
Vulnerability
99.6
License
TypeScript (89.97%)
JavaScript (10.03%)
Total Downloads
3,858
Last Day
1
Last Week
1
Last Month
6
Last Year
64
10 Commits
1 Watching
1 Branches
1 Contributors
Minified
Minified + Gzipped
Latest Version
0.0.1
Package Id
re-use-debounce@0.0.1
Unpacked Size
155.05 kB
Size
60.95 kB
File Count
10
Cumulative downloads
Total Downloads
Last day
0%
1
Compared to previous day
Last week
-50%
1
Compared to previous week
Last month
100%
6
Compared to previous month
Last year
-4.5%
64
Compared to previous year
Reuse lodash debounce as React hook
$ npm install re-use-debounce
Note: This libaray expects that you already depend on lodash 4.
1import React from 'react'; 2import useDebounce from 're-use-debounce'; 3 4function MyComponent(props) { 5 const [value, setValue] = React.useState(''); 6 7 const [debouncedValue, setDebouncedValue] = React.useState(''); 8 useDebounce(value, setDebouncedValue, 300); 9 10 React.useEffect(() => { 11 console.log(`debouncedValue: ${debouncedValue}`); 12 }, [debouncedValue]) 13 14 return ( 15 <input value={value} onChange={event => setValue(event.target.value)} /> 16 ); 17}
Type: any
The value that is being debounced
Type: function
The function to debounce
Type: number
The number of milliseconds to debounce
Type: Object
Type: boolean
Default: false
Specify invoking on the leading edge of the timeout.
Type: boolean
Default: true
Specify invoking on the trailing edge of the timeout.
Type: number
Default: undefined
The maximum time onChange
is allowed to be delayed before it's invoked.
MIT © Sindre Seppola
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
license file detected
Details
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
Found 0/10 approved changesets -- score normalized to 0
Reason
no SAST tool detected
Details
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
46 existing vulnerabilities detected
Details
Score
Last Scanned on 2025-01-06
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