You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -92,12 +92,21 @@ The `IWebAssemblyHostEnvironment.BaseAddress` property can be used during startu
92
92
93
93
### Configuration
94
94
95
-
As of the ASP.NET Core 3.2 Preview 3 release ([current release is 3.2 Preview 4](xref:blazor/get-started)), Blazor WebAssembly supports configuration from:
95
+
Blazor WebAssembly supports configuration from:
96
96
97
-
**wwwroot/appsettings.json*
98
-
**wwwroot/appsettings.{ENVIRONMENT}.json*
97
+
* The [File Configuration Provider](xref:fundamentals/configuration/index#file-configuration-provider) for app settings files by default:
98
+
**wwwroot/appsettings.json*
99
+
**wwwroot/appsettings.{ENVIRONMENT}.json*
100
+
* Other [configuration providers](xref:fundamentals/configuration/index) registered by the app.
99
101
100
-
Add an *appsettings.json* file in the *wwwroot* folder:
102
+
> [!WARNING]
103
+
> Configuration in a Blazor WebAssembly app is visible to users. **Don't store app secrets or credentials in configuration.**
104
+
105
+
For more information on configuration providers, see <xref:fundamentals/configuration/index>.
106
+
107
+
#### App settings configuration
108
+
109
+
*wwwroot/appsettings.json*:
101
110
102
111
```json
103
112
{
@@ -117,8 +126,113 @@ Inject an <xref:Microsoft.Extensions.Configuration.IConfiguration> instance into
117
126
<p>Message: @Configuration["message"]</p>
118
127
```
119
128
120
-
> [!WARNING]
121
-
> Configuration in a Blazor WebAssembly app is visible to users. **Don't store app secrets or credentials in configuration.**
129
+
#### Provider configuration
130
+
131
+
The following example uses a <xref:Microsoft.Extensions.Configuration.Memory.MemoryConfigurationSource> and the [File Configuration Provider](xref:fundamentals/configuration/index#file-configuration-provider) to supply additional configuration:
0 commit comments