Skip to content

Commit

Permalink
fix useEffect deps
Browse files Browse the repository at this point in the history
  • Loading branch information
toviszsolt committed Apr 19, 2024
1 parent 885075f commit 2a254a4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/useScrollObserver.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ const useScrollObserver = ({ root, rootMargin, threshold }) => {
return () => {
observer.disconnect();
};
}, []);
}, [idsRef, root, rootMargin, threshold]);

return { idsRef, activeLink };
};
Expand Down

0 comments on commit 2a254a4

Please sign in to comment.