Skip to content

Commit c897b43

Browse files
authored
Blazor Pre3 final updates for release (#35200)
1 parent f5ea8eb commit c897b43

File tree

3 files changed

+10
-24
lines changed

3 files changed

+10
-24
lines changed

Diff for: aspnetcore/blazor/call-web-api.md

+2
Original file line numberDiff line numberDiff line change
@@ -992,6 +992,8 @@ To opt-out of response streaming globally, use either of the following approache
992992
993993
* Set the `DOTNET_WASM_ENABLE_STREAMING_RESPONSE` environment variable to `false` or `0`.
994994
995+
............. AND REMOVE THE NEXT LINE .............
996+
995997
-->
996998

997999
To opt-out of response streaming globally, set the `DOTNET_WASM_ENABLE_STREAMING_RESPONSE` environment variable to `false` or `0`.

Diff for: aspnetcore/blazor/fundamentals/routing.md

+1-7
Original file line numberDiff line numberDiff line change
@@ -1626,13 +1626,7 @@ Use a <xref:Microsoft.AspNetCore.Components.Routing.NavLink> component in place
16261626

16271627
There are two <xref:Microsoft.AspNetCore.Components.Routing.NavLinkMatch> options that you can assign to the `Match` attribute of the `<NavLink>` element:
16281628

1629-
<!-- UPDATE 10.0 PREVIEW3
1630-
Change `DisableMatchAllIgnoresLeftUriPart` to
1631-
`EnableMatchAllForQueryStringAndFragmentSwitchKey`
1632-
set to `true`.
1633-
-->
1634-
1635-
* <xref:Microsoft.AspNetCore.Components.Routing.NavLinkMatch.All?displayProperty=nameWithType>: The <xref:Microsoft.AspNetCore.Components.Routing.NavLink> is active when it matches the current URL, ignoring the query string and fragment. To include matching on the query string/fragment, use the `Microsoft.AspNetCore.Components.Routing.NavLink.DisableMatchAllIgnoresLeftUriPart` [`AppContext` switch](/dotnet/fundamentals/runtime-libraries/system-appcontext).
1629+
* <xref:Microsoft.AspNetCore.Components.Routing.NavLinkMatch.All?displayProperty=nameWithType>: The <xref:Microsoft.AspNetCore.Components.Routing.NavLink> is active when it matches the current URL, ignoring the query string and fragment. To include matching on the query string/fragment, use the `Microsoft.AspNetCore.Components.Routing.NavLink.EnableMatchAllForQueryStringAndFragmentSwitchKey` [`AppContext` switch](/dotnet/fundamentals/runtime-libraries/system-appcontext) set to `true`.
16361630
* <xref:Microsoft.AspNetCore.Components.Routing.NavLinkMatch.Prefix?displayProperty=nameWithType> (*default*): The <xref:Microsoft.AspNetCore.Components.Routing.NavLink> is active when it matches any prefix of the current URL.
16371631

16381632
:::moniker-end

Diff for: aspnetcore/release-notes/aspnetcore-10/includes/blazor.md

+7-17
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ For more information, see <xref:blazor/fundamentals/signalr?view=aspnetcore-10.0
4747

4848
### Ignore the query string and fragment when using `NavLinkMatch.All`
4949

50-
The `NavLink` component now ignores the query string and fragment when using the `NavLinkMatch.All` value for the `Match` parameter. This means that the link retains the `active` class if the URL path matches but the query string or fragment change. To revert to the original behavior, use the `Microsoft.AspNetCore.Components.Routing.NavLink.DisableMatchAllIgnoresLeftUriPart` [`AppContext` switch](/dotnet/fundamentals/runtime-libraries/system-appcontext).
50+
The `NavLink` component now ignores the query string and fragment when using the `NavLinkMatch.All` value for the `Match` parameter. This means that the link retains the `active` class if the URL path matches but the query string or fragment change. To revert to the original behavior, use the `Microsoft.AspNetCore.Components.Routing.NavLink.EnableMatchAllForQueryStringAndFragmentSwitchKey` [`AppContext` switch](/dotnet/fundamentals/runtime-libraries/system-appcontext) set to `true`.
5151

5252
You can also override the `ShouldMatch` method on `NavLink` to customize the matching behavior:
5353

@@ -90,15 +90,15 @@ The following example uses the `CloseColumnOptionsAsync` method to close the col
9090
}
9191
```
9292

93-
<!-- PREVIEW 3 ..... NOTE CONTENT CHANGE FOR `<WasmEnableStreamingResponse>` BELOW!!!!!
94-
9593
### Response streaming is opt-in and how to opt-out
9694

9795
In prior Blazor releases, response streaming for <xref:System.Net.Http.HttpClient> requests was opt-in. Now, response streaming is enabled by default.
9896

9997
This is a breaking change because calling <xref:System.Net.Http.HttpContent.ReadAsStreamAsync%2A?displayProperty=nameWithType> for an <xref:System.Net.Http.HttpResponseMessage.Content%2A?displayProperty=nameWithType> (`response.Content.ReadAsStreamAsync()`) returns a `BrowserHttpReadStream` and no longer a <xref:System.IO.MemoryStream>. `BrowserHttpReadStream` doesn't support synchronous operations, such as `Stream.Read(Span<Byte>)`. If your code uses synchronous operations, you can opt-out of response streaming or copy the <xref:System.IO.Stream> into a <xref:System.IO.MemoryStream> yourself.
10098

101-
DON'T USE (comment out) ..............
99+
<!-- UNCOMMENT FOR PREVIEW 4? ...
100+
Waiting on https://github.com/dotnet/runtime/issues/97449
101+
... and update the Call web API article Line 983
102102
103103
To opt-out of response streaming globally, use either of the following approaches:
104104
@@ -110,7 +110,9 @@ To opt-out of response streaming globally, use either of the following approache
110110
111111
* Set the `DOTNET_WASM_ENABLE_STREAMING_RESPONSE` environment variable to `false` or `0`.
112112
113-
..................... UNTIL https://github.com/dotnet/runtime/issues/97449 IS RESOLVED AND RELEASED.
113+
............. AND REMOVE THE NEXT LINE .............
114+
115+
-->
114116

115117
To opt-out of response streaming globally, set the `DOTNET_WASM_ENABLE_STREAMING_RESPONSE` environment variable to `false` or `0`.
116118

@@ -122,16 +124,6 @@ requestMessage.SetBrowserResponseStreamingEnabled(false);
122124

123125
For more information, see [`HttpClient` and `HttpRequestMessage` with Fetch API request options (*Call web API* article)](xref:blazor/call-web-api?view=aspnetcore-10.0#httpclient-and-httprequestmessage-with-fetch-api-request-options).
124126

125-
XXXXXXXXXXXXXXXXXXXX CHANGE EARLIER COVERAGE XXXXXXXXXXXXXXXXXXXX
126-
127-
In the "Ignore the query string and fragment when using `NavLinkMatch.All`" section, change
128-
`DisableMatchAllIgnoresLeftUriPart` to `EnableMatchAllForQueryStringAndFragmentSwitchKey`
129-
set to `true`.
130-
131-
Also make this change in the *Routing* article at Line 1633.
132-
133-
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
134-
135127
### Client-side fingerprinting
136128

137129
Last year, the release of .NET 9 introduced [server-side fingerprinting](https://en.wikipedia.org/wiki/Fingerprint_(computing)) of static assets in Blazor Web Apps with the introduction of [Map Static Assets routing endpoint conventions (`MapStaticAssets`)](xref:fundamentals/map-static-files), the [`ImportMap` component](xref:blazor/fundamentals/static-files#importmap-component), and the <xref:Microsoft.AspNetCore.Components.ComponentBase.Assets?displayProperty=nameWithType> property (`@Assets["..."]`) to resolve fingerprinted JavaScript modules. For .NET 10, you can opt-into client-side fingerprinting of JavaScript modules for standalone Blazor WebAssembly apps.
@@ -288,5 +280,3 @@ else
288280
```
289281

290282
For more information, see <xref:blazor/components/prerender?view=aspnetcore-10.0#persist-prerendered-state>. Additional API implementation notes, which are subject to change at any time, are available in [[Blazor] Support for declaratively persisting component and services state (`dotnet/aspnetcore` #60634)](https://github.com/dotnet/aspnetcore/pull/60634).
291-
292-
-->

0 commit comments

Comments
 (0)