I have made a xib file of marker (Custom Marker), and assigning that xib file to marker.icon property. This xib file have superView and image inside it, But when it renders on Google Map, image inside SuperView displaces from the bottom as shown in attached image.
And it is happening when I give Google Map View bottom constraints from superView of the ViewController. From safeArea, it is working fine. I have tried in iPhoneX.
Assigning Xib file to Google Marker.
marker.iconView = createMarker(projectIndex: i)
Preparing marker method:
private func createMarker(projectIndex: Int) -> UIView {
let marker = MapMarker(frame: CGRect(x: 0, y: 0, width: 50, height: 50))
marker.updateMarker(project: projects[projectIndex])
marker.tag = projectIndex
marker.addGestureRecognizer(UITapGestureRecognizer(target: self, action: #selector(onTapMarker)))
return marker
}
I have spent hours on it but unable to find the bug, Please help me solve this. Thanks!

