Skip to content

Commit

Permalink
Remove explicit ref from dependencies list
Browse files Browse the repository at this point in the history
  • Loading branch information
TrySound committed Jul 7, 2019
1 parent 31bbcc4 commit 6003b51
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/usePopper.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ export default function usePopper(
if (popperInstanceRef.current) {
popperInstanceRef.current.scheduleUpdate();
}
}, [popperInstanceRef]);
}, []);

const [state, setState] = useState({
placement,
Expand All @@ -62,7 +62,7 @@ export default function usePopper(
? popperInstanceRef.current.enableEventListeners()
: popperInstanceRef.current.disableEventListeners();
}
}, [eventsEnabled, popperInstanceRef]);
}, [eventsEnabled]);

useEffect(() => {
if (!enabled || referenceElement === null || popperElement === null) {
Expand Down

0 comments on commit 6003b51

Please sign in to comment.