Created
March 5, 2020 13:33
-
-
Save sueLan/8286d5eec0148ab1fad570c98ec0cc17 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
_updateViewableItems(data: any) { | |
const {getItemCount} = this.props; | |
this._viewabilityTuples.forEach(tuple => { | |
tuple.viewabilityHelper.onUpdate( | |
getItemCount(data), | |
// contentOffset of the list | |
this._scrollMetrics.offset, | |
// 🌟 viewportHeight | |
this._scrollMetrics.visibleLength, | |
this._getFrameMetrics, | |
this._createViewToken, | |
tuple.onViewableItemsChanged, | |
this.state, | |
); | |
}); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment