useMap
A React-friendly wrapper for the native JavaScript Map object.
Live Demo Placeholder
Interactive demo coming soon.
Usage Example
1import { useMap } from '@danixsoft/hooks';
2
3function Example() {
4 const [map, actions] = useMap<string, string>(new Map());
5
6 return (
7 <div>
8 <button onClick={() => actions.set('hello', 'world')}>Set Value</button>
9 </div>
10 );
11}