Having problems getting the different arrays content from geocoder results.
item.formatted_address works but not item.address_components.locality?
ge
I used a lodash function called find which returns the object that the predicate returns true for. As simple as that!
let city = find(result, (address) => { return typeof find(address.types, (a) => { return a === 'locality'; }) === 'string'; });