I am using the below code to try to get my current location:
componentDidMount() {
    this.watchID = navigator.geolocation.watchPosition((position) => {
        let region = {
            latitude:       position.coords.latitude,
            longitude:      position.coords.longitude,
            latitudeDelta:  0.00922*1.5,
            longitudeDelta: 0.00421*1.5,
            enableHighAccuracy: true
        }
        this.onRegionChange(region, region.latitude, region.longitude);
    });
}
And I am getting:
Attempt to invoke interface method 'boolean abi26_0_0.com.facebook.react.bridge.ReadableMap.hasKey(java.lang.String)' on a null object reference
Which is triggering on this line:
this.watchID = navigator.geolocation.watchPosition((position) => {
Is there something I need to import for this to work maybe? I can't find anything online about this.



react-native init? If so, did you do all the required configurations?