[fix] Add getNativeScrollRef to FlatList

Fix #1560
Close #1563
This commit is contained in:
Nicolas Gallagher
2020-04-20 20:37:36 -07:00
parent 7ab3cf0d42
commit ac945761e6
@@ -428,6 +428,15 @@ class FlatList<ItemT> extends React.PureComponent<Props<ItemT>, void> {
}
}
/**
* Provides a reference to the underlying host component
*/
getNativeScrollRef() {
if (this._listRef) {
return this._listRef.getScrollRef();
}
}
getScrollableNode() {
if (this._listRef) {
return this._listRef.getScrollableNode();