I'm trying to get the position of a component in react native.
Say I have a view:
<ScrollView>
lots of items...
lots of items...
lots of items...
<View></View>
</ScrollView>
In the end I want to be able to eventually scroll to where the View is.
This link shows how to get the position using the native ui manager, however when ran it returns:
"Attempted to measure layout but offset or dimensions were NaN"
React Native: Getting the position of an element
I've attempted
this.refs.VIEW.measure((ox, oy, width, height, px, py) => {
//ox ... py all = 0
});