I want to change my google map style in ios. For that I am trying to implement this code. GMSMapStyle
I am importing import GoogleMaps
. But I am getting this error Use of unresolved identifier GMSMapStyle
. Can anybody help me to which module I have to import to avoid this error. Thanks in advance
While updating an app, I was getting a similar error but with mapType:
'Use of unresolved identifier 'kGMSTypeTerrain' with the following code:
@IBOutlet weak var googleMapView: GMSMapView!
googleMapView.mapType = kGMSTypeTerrain
Took me a couple of days to resolve this item. I thought I had an issue with my GoogleMaps IOS api so did a cocoa pod install (when I should of done a pod update) but it did not fix the issue. I finally came across the issue noted above with mapStyle. As it turns out, with Swift 3,
googleMapView.mapType = kGMSTypeTerrain
should be changed to
googleMapView.mapType = .terrain
Likewise for the other map types.
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