Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
source: async (answers, input = '') =>
Object.values(countries)
.filter(country => country.toLowerCase().startsWith(input.toLowerCase()))
.sort(),
};
function getCountryCodeByName(country) {
return Object.keys(countries).find(key => countries[key].includes(country));
}