Open 24dev opened 5 years ago
Big fan of the library, looking forward to the new version and community migration!
Problem is, I am trying to render a circle on the map, like this issue: https://github.com/nitaliano/react-native-mapbox-gl/issues/945
Unfortunately I cannot get LineLayer to work at all, every time I add it the app crashes with no error message or logs, on map load. If I remove the LineLayer for something like Text or View everything is okay (except the circle doesn't show).
This is my code:
import circle from '@turf/circle'; const circleCenter = [-0.121315, 51.510519]; const circleRadius = 10; const circleOptions = { steps: 50, units: 'kilometers', }; <Mapbox.MapView styleURL={Mapbox.StyleURL.Streets} centerCoordinate={location} > <Mapbox.ShapeSource shape={circle(circleCenter, circleRadius, circleOptions)}> <Mapbox.LineLayer /> </Mapbox.ShapeSource> </Mapbox.MapView>
Adding styles to the LineLayer seems to make no difference.
Using v6.1.3 of this library, and v0.57.1 of React Native.
I am also seeing this issue Using v6.1.4 and v0.57.8 of RN
Did anyone manage to do this? Sorry to comment in an old thread.
Big fan of the library, looking forward to the new version and community migration!
Problem is, I am trying to render a circle on the map, like this issue: https://github.com/nitaliano/react-native-mapbox-gl/issues/945
Unfortunately I cannot get LineLayer to work at all, every time I add it the app crashes with no error message or logs, on map load. If I remove the LineLayer for something like Text or View everything is okay (except the circle doesn't show).
This is my code:
Adding styles to the LineLayer seems to make no difference.
Using v6.1.3 of this library, and v0.57.1 of React Native.