In the previous posts, we’ve created the Model, Location, and Networking components, and we’ll use them to design our ViewModel. The ViewModel will need a method to get the current location, and another one to get amenities. Here’s how we can define the protocol for the ViewModel. protocol MapViewModelConfirming { func getCurrentLocation() -> (Double, Double) func getAmenities(in range: Int, type: AmenityType, completion: @escaping CompletionBlock) } We’ll also need a protocol to whic...