Aspnetcore has a sample of Blazor wasm standalone in-tree - #64624
Aspnetcore has a sample of Blazor wasm standalone in-tree#64624ilonatommy wants to merge 5 commits into
Conversation
There was a problem hiding this comment.
Pull request overview
This PR adds a new in-tree sample application for Blazor WebAssembly Standalone to complement the existing Blazor Web sample. The sample demonstrates pure client-side hosting and provides a canonical reference project for developers and automated tools working with standalone WebAssembly applications.
Key Changes
- New BlazorWasmStandalone sample project with standard Blazor components (Counter, Weather, Home pages)
- Complete project structure including layouts, styling, and static assets
- Added DevServer project reference to ProjectReferences.props
Reviewed changes
Copilot reviewed 17 out of 20 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| BlazorWasmStandalone.csproj | Project configuration for Blazor WebAssembly SDK with necessary references |
| Program.cs | Application entry point with WebAssembly host configuration |
| App.razor | Router setup with NotFound page handling |
| Layout components | MainLayout and NavMenu for consistent navigation structure |
| Page components | Home, Counter, and Weather demonstration pages |
| wwwroot files | Static assets including index.html, CSS, Bootstrap, favicon, and sample data |
| ProjectReferences.props | Added DevServer project reference for build integration |
|
@ilonatommy have you checked under webassembly/samples? I believe there is one there. |
yes but old one and not standalone: |
We can check it this way: searching for |
|
Looks like this PR hasn't been active for some time and the codebase could have been changed in the meantime. |
|
@ilonatommy I think this was superseded by #67497 |
|
I see, yes, https://github.com/dotnet/aspnetcore/tree/main/src/Components/WebAssembly/Samples/BlazorWebAssemblyStandalone provides same functionality. Closing. |
We should keep our samples aligned with the scenarios we actively invest in. We already ship an in-tree sample for Blazor Web (https://github.com/dotnet/aspnetcore/tree/main/src/Components/Samples/BlazorUnitedApp) , but we still lacked a counterpart for Blazor WebAssembly Standalone. Adding this sample fills that gap and gives both developers and automated agents a canonical project to reference when troubleshooting or experimenting with pure client-side hosting.
I am not sure about the placing of the sample. Another location would be next to wasm hosted sample: https://github.com/dotnet/aspnetcore/tree/main/src/Components/WebAssembly/Samples/HostedBlazorWebassemblyApp
that is the old version of blazor web.