0.0.21 • Published 2 years ago
@gadeoli/rjs-hooks-library v0.0.21
RJS Hook Library
Some (almost all) hooks has been copied from internet foruns. If necessary look from source info to check who created the hook.
How to maintain
- Clone
- NVM use 16.14.2 (node 16.14.2 / npm 8.5.0)
- npm i
- make changes
- git add / git commit / git push
- npm run publish (custom command)
Hooks
- useElementSize (Get element sizes using ref)
- useOnClickOutside (Listen when clicked outside component using ref)
- usePersistedState (An option to persist state in local storage)
- usePrevious (Keep state value between current and previous render)
- useWindowSize (Get window sizes)
- useTimer (a count down minute / seconds)
- useClickOutside (An event handler to trigger an action by outside-click-element using ref)
- useOnPressKey (An event handler to trigger an action by key press using ref)
Use
import {useElementSize} from '@gadeoli/rjs-hooks-library';
Sources
useElementSize
useOnClickOutside
usePersistedState
usePrevious
useTimer
useWindowSize
useClickOutside
useOnPressKey
0.0.20
2 years ago
0.0.21
2 years ago
0.0.18
2 years ago
0.0.19
2 years ago
0.0.17
2 years ago
0.0.15
3 years ago
0.0.16
3 years ago
0.0.13
3 years ago
0.0.14
3 years ago
0.0.10
3 years ago
0.0.11
3 years ago
0.0.12
3 years ago
0.0.9
3 years ago
0.0.8
3 years ago
0.0.7
3 years ago
0.0.5
3 years ago
0.0.4
3 years ago
0.0.3
3 years ago
0.0.2
3 years ago
0.0.1
3 years ago