Open developervariety opened 1 year ago
Some options for this:
tzdata
: https://www.npmjs.com/package/tzdatausing NodaTime;
void Main()
{
var faker = new Faker();
var timezones = DateTimeZoneProviders.Tzdb.Ids.ToArray();
var randomTimezones = Enumerable.Range(1, 10)
.Select(_ => faker.PickRandom(timezones));
randomTimezones.Dump();
}
Please describe why you are requesting a feature
It would go well with random locale.
Please provide a code example of what you are trying to achieve
A list of timezone IDs I've found: https://raw.githubusercontent.com/mattjohnsonpint/TimeZoneNames/main/src/TimeZoneNames.DataBuilder/data/zone-precedence.txt
Is the feature something that currently cannot be done? No
What alternatives have you considered? Randomizing from a list
Is this feature request any issues or current problems? No
Has the feature been requested in the past? No
If the feature request is approved, would you be willing to submit a PR? No