benkeen / generatedata

A powerful, feature-rich, random test data generator.
https://generatedata.com
2.22k stars 611 forks source link

Check `regionNames` string in countries i18n files #776

Open benkeen opened 2 years ago

benkeen commented 2 years ago

Discussed in https://github.com/benkeen/generatedata/discussions/773

As discussed above. Possibly we can just ditch this value now.

andrefortin commented 7 months ago

It is not being referenced except for in the type [CountryDataType] found in the file "/client/types/countries.d.ts"

export type CountryDataType = { countrySlug: string; countryName: string; regionNames: string; continent: Continent; regions: Region[]; extendedData: ExtendedData; };

We are actually using the value incorrectly as it represents "What does this country call its regional subdivisions?".

For the USA is should simply be: "States", for Canada: "Provinces".

Now that the user interface uses the generic term "Region" and it gets translated in the UI this value is not required. However I'd be for keeping it and simply updating it to the actual correct usage in the files.