I created new map style with Mapbox Studio, then I uploaded it to my account (so I see it in styles tab), then I added StyleID to my iOS MGLMapView but when I run app it throws error
[ERROR] {Map}[Setup]: loading style failed: HTTP status code 404
If I don’t use my style, map is working correctly.
Try this in viewDidload:
mapView.styleURL = NSURL(string: "asset://styles/dark-v7.json")
Update 1:
For this moment it is not possible to use custom map style with Mapbox GL for iOS.
'First steps with Mapbox GL for iOS':
Changing the map style
At the moment, Mapbox GL comes bundled with a handful of map styles. That’ll all change in a few months, but for now let’s change the map style to Mapbox Dark...
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With