Last active
July 14, 2018 10:13
-
-
Save leny/d50199002f38e653c8aca95c93cc60a3 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const getReadableAddress = (street, number, zip, city, country) => { | |
if (street && number && zip) { | |
return [ | |
`${street} ${number}`, | |
`${zip} ${city}`, | |
country, | |
].join("\n"); | |
} | |
return `${city} (${country})`; | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment