[Blazor] Remove HotReload built-into Blazor WebAssembly#62777
Merged
Conversation
Co-authored-by: maraf <10020471+maraf@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] [Blazor] Remove HotReload built-into Blazor WebAssembly
[Blazor] Remove HotReload built-into Blazor WebAssembly
Jul 17, 2025
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR removes the built-in HotReload functionality from Blazor WebAssembly.
- Deletes the WebAssemblyHotReload implementation and its initialization.
- Cleans up related MSBuild property and public API entries.
- Removes JavaScript/TypeScript interop methods for HotReload.
Reviewed Changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| Microsoft.AspNetCore.Components.WebAssembly.props | Removed WebAssemblyHotReloadCapabilities MSBuild property |
| PublicAPI.Unshipped.txt | Removed HotReload API entries |
| PublicAPI.Shipped.txt | Removed HotReload API entries |
| HotReload/WebAssemblyHotReload.cs | Deleted the entire HotReload implementation class |
| Hosting/WebAssemblyHost.cs | Removed HotReload initialization block and unused usings |
| src/Components/Web.JS/src/GlobalExports.ts | Removed TypeScript interface definitions for HotReload |
| src/Components/Web.JS/src/Boot.WebAssembly.Common.ts | Removed JavaScript interop methods for HotReload |
maraf
reviewed
Jul 18, 2025
| Microsoft.AspNetCore.Components.WebAssembly.Hosting.WebAssemblyHostConfiguration.this[string! key].set -> void | ||
| Microsoft.AspNetCore.Components.WebAssembly.Hosting.WebAssemblyHostConfiguration.WebAssemblyHostConfiguration() -> void | ||
| Microsoft.AspNetCore.Components.WebAssembly.Hosting.WebAssemblyHostEnvironmentExtensions | ||
| Microsoft.AspNetCore.Components.WebAssembly.HotReload.WebAssemblyHotReload |
Member
There was a problem hiding this comment.
Instead of removing APIs from here, mark them as removed in PublicAPI.Unshipped.txt
Documentation says:
Removed APIs
A new entry needs to be added to the PublicAPI.Unshipped.txt file for a removed API. For example:
#nullable enable
*REMOVED*Microsoft.Builder.OldApplicationBuilder.New() -> Microsoft.AspNetCore.Builder.IApplicationBuilder!
Contributor
Author
There was a problem hiding this comment.
Fixed in commit 2805982. The HotReload APIs are now marked as REMOVED in PublicAPI.Unshipped.txt instead of being deleted from PublicAPI.Shipped.txt.
…eting Co-authored-by: maraf <10020471+maraf@users.noreply.github.com>
javiercn
approved these changes
Jul 18, 2025
pavelsavara
approved these changes
Jul 18, 2025
Member
|
/ba-g |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Do not merge before dotnet/sdk#49800
This PR removes the built-in HotReload functionality from Blazor WebAssembly as requested in the issue.
Changes Made
Removed Files
src/Components/WebAssembly/WebAssembly/src/HotReload/WebAssemblyHotReload.cs- The main HotReload implementation classsrc/Components/WebAssembly/WebAssembly/src/HotReload/- Empty directory after file removalUpdated Files
PublicAPI.Shipped.txt - Removed 3 HotReload-related public API entries:
Microsoft.AspNetCore.Components.WebAssembly.HotReload.WebAssemblyHotReloadApplyHotReloadDeltamethodGetApplyUpdateCapabilitiesmethodPublicAPI.Unshipped.txt - Removed 19 HotReload-related entries:
WebAssemblyHotReload.Deltastruct and all its propertiesWebAssemblyHotReload.LogEntrystruct and all its propertiesApplyHotReloadDeltasmethodBoot.WebAssembly.Common.ts - Removed JavaScript interop methods:
applyHotReload(obsolete method)applyHotReloadDeltasgetApplyUpdateCapabilitiesGlobalExports.ts - Removed TypeScript interface definitions for the removed methods
WebAssemblyHost.cs - Removed:
using Microsoft.AspNetCore.Components.WebAssembly.HotReload;using System.Reflection.Metadata;(now unused)Microsoft.AspNetCore.Components.WebAssembly.props - Removed
WebAssemblyHotReloadCapabilitiespropertyImpact
This is a clean removal of the self-contained WebAssembly HotReload functionality without affecting:
Testing
Fixes #62776.
Fixes #62371.
Contributes to #61272
💬 Share your feedback on Copilot coding agent for the chance to win a $200 gift card! Click here to start the survey.