|
1 | 1 | # useHooks
|
2 | 2 |
|
3 |
| -A collection of 50 RSC safe React hooks |
| 3 | +A collection of Server Component safe React Hooks – from the ui.dev team |
4 | 4 |
|
5 | 5 | ## Standard
|
6 | 6 |
|
7 | 7 | ### Install
|
8 | 8 |
|
9 | 9 | `npm i @uidotdev/usehooks`
|
10 | 10 |
|
11 |
| -- [useBattery](https://usehooks.com/useBattery) |
12 |
| -- [useClickAway](https://usehooks.com/useClickAway) |
13 |
| -- [useCopyToClipboard](https://usehooks.com/useCopyToClipboard) |
14 |
| -- [useCounter](https://usehooks.com/useCounter) |
15 |
| -- [useDebounce](https://usehooks.com/useDebounce) |
16 |
| -- [useDefault](https://usehooks.com/useDefault) |
17 |
| -- [useDocumentTitle](https://usehooks.com/useDocumentTitle) |
18 |
| -- [useFavicon](https://usehooks.com/useFavicon) |
19 |
| -- [useGeolocation](https://usehooks.com/useGeolocation) |
20 |
| -- [useHistoryState](https://usehooks.com/useHistoryState) |
21 |
| -- [useHover](https://usehooks.com/useHover) |
22 |
| -- [useIdle](https://usehooks.com/useIdle) |
23 |
| -- [useIntersectionObserver](https://usehooks.com/useIntersectionObserver) |
24 |
| -- [useIsClient](https://usehooks.com/useIsClient) |
25 |
| -- [useIsFirstRender](https://usehooks.com/useIsFirstRender) |
26 |
| -- [useList](https://usehooks.com/useList) |
27 |
| -- [useLockBodyScroll](https://usehooks.com/useLockBodyScroll) |
28 |
| -- [useLongPress](https://usehooks.com/useLongPress) |
29 |
| -- [useMap](https://usehooks.com/useMap) |
30 |
| -- [useMeasure](https://usehooks.com/useMeasure) |
31 |
| -- [useMediaQuery](https://usehooks.com/useMediaQuery) |
32 |
| -- [useMouse](https://usehooks.com/useMouse) |
33 |
| -- [useNetworkState](https://usehooks.com/useNetworkState) |
34 |
| -- [useObjectState](https://usehooks.com/useObjectState) |
35 |
| -- [useOrientation](https://usehooks.com/useOrientation) |
36 |
| -- [usePreferredLanguage](https://usehooks.com/usePreferredLanguage) |
37 |
| -- [usePrevious](https://usehooks.com/usePrevious) |
38 |
| -- [useQueue](https://usehooks.com/useQueue) |
39 |
| -- [useRenderCount](https://usehooks.com/useRenderCount) |
40 |
| -- [useRenderInfo](https://usehooks.com/useRenderInfo) |
41 |
| -- [useScript](https://usehooks.com/useScript) |
42 |
| -- [useSet](https://usehooks.com/useSet) |
43 |
| -- [useThrottle](https://usehooks.com/useThrottle) |
44 |
| -- [useToggle](https://usehooks.com/useToggle) |
45 |
| -- [useVisibilityChange](https://usehooks.com/useVisibilityChange) |
46 |
| -- [useWindowScroll](https://usehooks.com/useWindowScroll) |
47 |
| -- [useWindowSize](https://usehooks.com/useWindowSize) |
| 11 | +### Hooks |
| 12 | + |
| 13 | +- [useBattery](https://usehooks.com/usebattery) |
| 14 | +- [useClickAway](https://usehooks.com/useclickAway) |
| 15 | +- [useCopyToClipboard](https://usehooks.com/usecopytoclipboard) |
| 16 | +- [useCounter](https://usehooks.com/usecounter) |
| 17 | +- [useDebounce](https://usehooks.com/usedebounce) |
| 18 | +- [useDefault](https://usehooks.com/usedefault) |
| 19 | +- [useDocumentTitle](https://usehooks.com/usedocumentTitle) |
| 20 | +- [useFavicon](https://usehooks.com/usefavicon) |
| 21 | +- [useGeolocation](https://usehooks.com/usegeolocation) |
| 22 | +- [useHistoryState](https://usehooks.com/usehistoryState) |
| 23 | +- [useHover](https://usehooks.com/usehover) |
| 24 | +- [useIdle](https://usehooks.com/useidle) |
| 25 | +- [useIntersectionObserver](https://usehooks.com/useintersectionobserver) |
| 26 | +- [useIsClient](https://usehooks.com/useisclient) |
| 27 | +- [useIsFirstRender](https://usehooks.com/useisfirstrender) |
| 28 | +- [useList](https://usehooks.com/uselist) |
| 29 | +- [useLockBodyScroll](https://usehooks.com/uselockbodyscroll) |
| 30 | +- [useLongPress](https://usehooks.com/uselongpress) |
| 31 | +- [useMap](https://usehooks.com/usemap) |
| 32 | +- [useMeasure](https://usehooks.com/usemeasure) |
| 33 | +- [useMediaQuery](https://usehooks.com/usemediaquery) |
| 34 | +- [useMouse](https://usehooks.com/usemouse) |
| 35 | +- [useNetworkState](https://usehooks.com/usenetworkstate) |
| 36 | +- [useObjectState](https://usehooks.com/useobjectstate) |
| 37 | +- [useOrientation](https://usehooks.com/useorientation) |
| 38 | +- [usePreferredLanguage](https://usehooks.com/usepreferredlanguage) |
| 39 | +- [usePrevious](https://usehooks.com/useprevious) |
| 40 | +- [useQueue](https://usehooks.com/usequeue) |
| 41 | +- [useRenderCount](https://usehooks.com/userendercount) |
| 42 | +- [useRenderInfo](https://usehooks.com/userenderinfo) |
| 43 | +- [useScript](https://usehooks.com/usescript) |
| 44 | +- [useSet](https://usehooks.com/useset) |
| 45 | +- [useThrottle](https://usehooks.com/usethrottle) |
| 46 | +- [useToggle](https://usehooks.com/usetoggle) |
| 47 | +- [useVisibilityChange](https://usehooks.com/usevisibilitychange) |
| 48 | +- [useWindowScroll](https://usehooks.com/usewindowscroll) |
| 49 | +- [useWindowSize](https://usehooks.com/usewindowSize) |
48 | 50 |
|
49 | 51 | ## Experimental
|
50 | 52 |
|
51 | 53 | ### Install
|
52 | 54 |
|
53 | 55 | `npm i @uidotdev/usehooks@experimental react@experimental react-dom@experimental`
|
54 | 56 |
|
55 |
| -- [useContinuousRetry](https://usehooks.com/useContinuousRetry) |
56 |
| -- [useCountdown](https://usehooks.com/useCountdown) |
57 |
| -- [useEventListener](https://usehooks.com/useEventListener) |
58 |
| -- [useFetch](https://usehooks.com/useFetch) |
59 |
| -- [useInterval](https://usehooks.com/useInterval) |
60 |
| -- [useIntervalWhen](https://usehooks.com/useIntervalWhen) |
61 |
| -- [useKeyPress](https://usehooks.com/useKeyPress) |
62 |
| -- [useLocalStorage](https://usehooks.com/useLocalStorage) |
63 |
| -- [useLogger](https://usehooks.com/useLogger) |
64 |
| -- [usePageLeave](https://usehooks.com/usePageLeave) |
65 |
| -- [useRandomInterval](https://usehooks.com/useRandomInterval) |
66 |
| -- [useSessionStorage](https://usehooks.com/useSessionStorage) |
67 |
| -- [useTimeout](https://usehooks.com/useTimeout) |
| 57 | +### Hooks |
| 58 | + |
| 59 | +- [useContinuousRetry](https://usehooks.com/usecontinuousretry) |
| 60 | +- [useCountdown](https://usehooks.com/usecountdown) |
| 61 | +- [useEventListener](https://usehooks.com/useeventlistener) |
| 62 | +- [useFetch](https://usehooks.com/usefetch) |
| 63 | +- [useInterval](https://usehooks.com/useinterval) |
| 64 | +- [useIntervalWhen](https://usehooks.com/useintervalwhen) |
| 65 | +- [useKeyPress](https://usehooks.com/usekeypress) |
| 66 | +- [useLocalStorage](https://usehooks.com/uselocalstorage) |
| 67 | +- [useLogger](https://usehooks.com/uselogger) |
| 68 | +- [usePageLeave](https://usehooks.com/usepageleave) |
| 69 | +- [useRandomInterval](https://usehooks.com/userandominterval) |
| 70 | +- [useSessionStorage](https://usehooks.com/usesessionstorage) |
| 71 | +- [useTimeout](https://usehooks.com/usetimeout) |
0 commit comments