Skip to content

Commit

Permalink
fix: range reacts on container dimension change (#73)
Browse files Browse the repository at this point in the history
  • Loading branch information
Lukas742 authored Oct 20, 2020
1 parent d64056b commit 4299a9b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ export function useVirtual({
return () => {
element.removeEventListener('scroll', onScroll)
}
}, [parentRef.current, scrollKey, size /* required */])
}, [parentRef.current, scrollKey, size /* required */, outerSize /* required */])

const virtualItems = React.useMemo(() => {
const virtualItems = []
Expand Down

0 comments on commit 4299a9b

Please sign in to comment.