Skip to content

Commit 649ca2d

Browse files
committed
chore: Update docs
1 parent f347657 commit 649ca2d

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

client/src/lib/hooks/usetodo.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,9 @@ export default function useTodos () {
3333

3434
/**
3535
* The external store with available useSyncExternalStore-required methods:
36-
* subscribe() - Used and initialized internally by useSyncExternalStore
36+
* subscribe()
37+
* - Used and initialized internally by useSyncExternalStore for subscribing to external store events.
38+
* - This should return a clean-up function like in useEffect() with empty dependency arrays.
3739
* getSnapshot() - Returns the current (full) snapshot of the global data variable
3840
* getServerSnapshot() - Used in SSR
3941
*/

0 commit comments

Comments
 (0)