Closed kubabutkiewicz closed 5 months ago
Please fix the errors in your code example - More info.:
error: Parsing error: Unexpected token { at example.jsx:3:13:
1 |
2 | import {useFocusEffect, useNavigation} from '@react-navigation/native';
> 3 | import type {MapState} from '@rnmapbox/maps';
| ^
4 | import Mapbox, {MarkerView, setAccessToken} from '@rnmapbox/maps';
5 | import {forwardRef, memo, useCallback, useEffect, useImperativeHandle, useMemo, useRef, useState} from 'react';
6 | import {View} from 'react-native';
1 error found.```
Mapbox Implementation
Mapbox
Mapbox Version
default
React Native Version
0.74.2
Platform
Android
@rnmapbox/maps
version10.1.23
Standalone component to reproduce
Observed behavior and steps to reproduce
During migrating Expensify to RN 0.74+ we noticed crash of the app caused by rn mapbox
the error which we are getting is
Error: Exception in HostFunction: no non-static method "Lcom/rnmapbox/rnmbx/components/mapview/NativeMapViewModule;.setHandledMapChangedEvents(Ljava/lang/Double;Lcom/facebook/react/bridge/ReadableArray;Lcom/facebook/react/bridge/Promise;)V"
Here is a PR with migration https://github.com/Expensify/App/pull/40548/files I also checked on newest version of rn-mapbox but its happening the same.
More logs: React Native 0.74 upgrade logs.txt
Expected behavior
No response
Notes / preliminary analysis
No response
Additional links and references
No response