lbry-desktop/ui/util/country.js

19 lines
382 B
JavaScript
Raw Permalink Normal View History

2021-04-01 10:45:12 +02:00
import { countries as countryData } from 'country-data';
export const COUNTRIES = Array.from(
new Set(
countryData.all
.filter((country) => country.status !== 'deleted')
.map((country) => country.name)
.sort((a, b) => {
if (a > b) {
return 1;
}
if (b > a) {
return -1;
}
return 0;
})
)
);