description | page_type | languages | name | products | urlFragment | ||||
---|---|---|---|---|---|---|---|---|---|
Samples to accompany the official Microsoft Blazor documentation. |
sample |
|
Blazor sample applications |
|
blazor-samples |
Samples in this repository accompany the official Microsoft Blazor documentation.
To obtain a local copy of the sample apps in this repository, use either of the following approaches:
- Fork this repository and clone it to your local system.
- Select the Code button. Select Download ZIP to save the repository locally. Extract the saved Zip archive (
.zip
) to access the sample apps.
- Blazor Server with EF Core: ASP.NET Core Blazor Server with Entity Framework Core (EFCore)
- Blazor with SignalR: Use ASP.NET Core SignalR with Blazor
- Blazor WebAssembly scopes-enabled logging: ASP.NET Core Blazor logging: Client-side log scopes
- Blazor WebAssembly with ASP.NET Core Identity: Blazor WebAssembly with ASP.NET Core Identity
WARNING: Always follow an article's security guidance when implementing sample code.
Prior to the release of .NET 8, snippet sample apps for Blazor Server and Blazor WebAssembly provide the code examples that appear in Blazor articles. Many of the components in the snippet sample apps compile and run if copied to a local test app. However, the entire snippet sample apps aren't meant to be runnable demonstration sample apps, and not all of the components are completely functional. The purpose of the snippet sample apps prior to .NET 8's release is merely to supply code examples to documentation.
For the release of .NET 8 (and later releases), the sample apps for Blazor Web App and Blazor WebAssembly both supply snippets to articles and are fully working demonstration sample apps. All of the components in these apps function normally.
Blazor snippet sample apps
- Blazor Web App (.NET 8 or later)
- Blazor Server (.NET 7.0 or earlier)
- Blazor WebAssembly
For more information, see the Support requests section in the Blazor Fundamentals overview article.