Ok, I found a solution if anyone else will ever need it.
I added a UITapGestureRecognizer to my map view instance.
I used the MKMapView's convert(_:toCoordinateFrom:) to convert the touch point to the map coordinates
I created a MKMapPoint from that coordinate and checked if the MKPolygon renderer path contains the point
For the MKPolygon, being a MKShape after all, I used the .title property to assign my zone_id value parsed from the GeoJSON.
So I was able to identify which polygon was tapped.
I attached the code
MapView.swift
MapViewModel.swift
Post
Replies
Boosts
Views
Activity
Well, as it is being my first app, I did not know that i have to set also the price. I thought if I don't set any price, will be available for free. Anyway, now it's live.