`var ci = new CultureInfo("sv-SE") {DateTimeFormat = {ShortDatePattern = "yyyy-MM-dd"} };
app.UseRequestLocalization(
new RequestLocalizationOptions()
{
SupportedCultures = new List<CultureInfo> { ci },
SupportedUICultures = new List<CultureInfo> { ci },
DefaultRequestCulture = new RequestCulture(ci)
});`
We have this in startup/configure to make sure that the culture is set to swedish in the UI. and it has worked up until we upgraded to .Net 5. Now I have to add NumberFormat = { NegativeSign="-" } to stop it from returning Ascii 8722 as the negative sign.