Skip to content

Commit

Permalink
Add back the eslint disables
Browse files Browse the repository at this point in the history
  • Loading branch information
pksjce committed Nov 8, 2021
1 parent 90183a3 commit 9573b82
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/Portal/Portal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ export const Portal: React.FC<PortalProps> = ({children, onMount, containerName:
return () => {
parentElement.removeChild(element)
}
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [elementRef])

return createPortal(children, elementRef.current)
Expand Down
2 changes: 2 additions & 0 deletions src/hooks/useCombinedRefs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,10 @@ export function useCombinedRefs<T>(...refs: (ForwardedRef<T> | null | undefined)

return () => {
// ensure the refs get updated on unmount
// eslint-disable-next-line react-hooks/exhaustive-deps
setRefs(combinedRef.current)
}
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [...refs, combinedRef.current])

return combinedRef
Expand Down

0 comments on commit 9573b82

Please sign in to comment.