title: How to add click listener to selected mkannotationview?
body: <p>I need to click on annotation on the map. I can see selected annotation view like this <a href="https://i.stack.imgur.com/xk5Fz.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/xk5Fz.png" alt="mkannotationview"></a> </p>
  
  <p>I want to add click listener on this selected annotation view to open another view controller with annotation's details. How can I do this?</p>
  
  <pre><code>func mapView(_ mapView: MKMapView, didSelect view: MKAnnotationView) {
      if let selected = (view.annotation as? CustomAnnotation) {
          self.selectedAnnotation = selected
      }
  }
  
  </code></pre>
  
  <p><strong>Edited</strong></p>