Gathering detailed insights and metrics for use-mapped-state
Gathering detailed insights and metrics for use-mapped-state
Gathering detailed insights and metrics for use-mapped-state
Gathering detailed insights and metrics for use-mapped-state
npm install use-mapped-state
Typescript
Module System
Node Version
NPM Version
TypeScript (90.29%)
JavaScript (9.71%)
Total Downloads
0
Last Day
0
Last Week
0
Last Month
0
Last Year
0
MIT License
3 Stars
5 Commits
1 Watchers
17 Branches
1 Contributors
Updated on Mar 04, 2021
Latest Version
0.0.1
Package Id
use-mapped-state@0.0.1
Unpacked Size
5.70 kB
Size
2.47 kB
File Count
7
NPM Version
6.7.0
Node Version
11.12.0
Cumulative downloads
Total Downloads
Last Day
0%
NaN
Compared to previous day
Last Week
0%
NaN
Compared to previous week
Last Month
0%
NaN
Compared to previous month
Last Year
0%
NaN
Compared to previous year
1
1import useMappedState from 'use-mapped-state'; 2 3const Comp = () => { 4 const [state, setState, [value1, yoValue]] = useMappedState( 5 'initialValue', 6 value => value + 1, 7 value => 'Yo' + value 8 ); 9 10 return ( 11 <div> 12 <span>{state}</span> 13 <span>{value1}</span> 14 <span>{yoValue}</span> 15 <button onClick={() => setState('Cool')} /> 16 </div> 17 ); 18}; 19 20export default Comp;
The cool thing about this hook is that you get a typed return value of your map functions
1const [ 2 num, // number 3 setNum, // Dispatch.. 4 [ 5 value1, // number 6 value2, // string 7 value3, // object 8 ], 9] = useMappedState(1, value => value + 1, value => 'Yo' + value, value => ({ value }));
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/5 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
52 existing vulnerabilities detected
Details
Score
Last Scanned on 2025-07-07
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