-
Good evening, I am having trouble with the base map not showing when using a custom style. When I use a standard base map ( syleURL={MapboxGL.StyleURL.Light} ) the base map works fine. When I use a custom style, either with extra layers, or even unadulterated the base map will not show. The layers I have created on top of the base map do show though. I have tried to simplify things as much as I can to make sure nothing is interfering, but still get the issue. The screenshot shows what I get when using a custom style with a layer containing a geojson polygon. This is the simple code with the token and styleurl obfuscated, but correct when running. The only thing I can think is have got something set up incorrectly in Mapobox Studio, but my custom styles are published and show correctly in the UI when doing so. Any help would be much appreciated. Cheers! Will import React from 'react'; Mapbox.setAccessToken('xxxxxxxxxx'); const App = () => { export default App; const styles = StyleSheet.create({ |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
I solved this issue updating the
|
Beta Was this translation helpful? Give feedback.
Thanks Ladvace! This didn't work for me, but what has worked is creating a new style from a 'classic template' rather than a 'New Style', which I suspect is a 'Blank Style' and then loading tile sets from my codebase rather than creating layers on the base map.
Not sure whether this is the recommended approach and isn't in line with the "New York Bike Sheds" demo, but for now is fulfilling my needs.