According to this article Blazor WASM loads configuration by default from wwwroot/appsettings.json and wwwroot/appsettings.{environment}.json . However, when I generate Blazor WASM apps there are no such files under wwwroot. My dotnet version is 5.0.101, I am on Ubuntu 20.04, and my target framework is net5.0 . I do see files with such names in the Server project when I create a template hosted by ASP.NET core. Is that what it's actually referring to, or am I missing something else?
1
votes
2 Answers
1
votes
1
votes
Yep. In case you need a template, here is a basic template:
{
"Logging": {
"LogLevel": {
"Default": "Information",
"Microsoft": "Warning",
"Microsoft.Hosting.Lifetime": "Information"
}
},
"AllowedHosts": "*",
"ConnectionStrings": {
"MyDatabase": "Server=???;Initial Catalog=???;User ID=???;Password=???",
},
"ApiSettings": {
"SomeApiValue": "Some API value"
}
}