Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions .openpublishing.redirection.json
Original file line number Diff line number Diff line change
Expand Up @@ -1117,7 +1117,7 @@
},
{
"source_path": "aspnetcore/blazor/integrate-components.md",
"redirect_url": "/aspnet/core/blazor/components/prerendering-and-integration",
"redirect_url": "/aspnet/core/blazor/components/integration",
"redirect_document_id": false
},
{
Expand Down Expand Up @@ -1157,7 +1157,7 @@
},
{
"source_path": "aspnetcore/blazor/components/integrate-components-into-razor-pages-and-mvc-apps.md",
"redirect_url": "/aspnet/core/blazor/components/prerendering-and-integration",
"redirect_url": "/aspnet/core/blazor/components/integration",
"redirect_document_id": false
},
{
Expand Down Expand Up @@ -1317,6 +1317,11 @@
"source_path": "aspnetcore/blazor/images.md",
"redirect_url": "/aspnet/core/blazor/images-and-documents",
"redirect_document_id": false
},
{
"source_path": "aspnetcore/blazor/components/prerendering-and-integration.md",
"redirect_url": "/aspnet/core/blazor/components/integration",
"redirect_document_id": false
}
]
}
2 changes: 1 addition & 1 deletion aspnetcore/blazor/components/data-binding.md
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ Razor attribute binding is case-sensitive:

:::moniker range=">= aspnetcore-7.0"

To execute asynchronous logic after binding, use `@bind:after="{EVENT}"` with a DOM event for the `{EVENT}` placeholder. An assigned C# method isn't executed until the bound value is assigned synchronously.
To execute asynchronous logic after binding, use `@bind:after="{DELEGATE}"`, where the `{DELEGATE}` placeholder is a C# delegate (method). An assigned C# delegate isn't executed until the bound value is assigned synchronously.

Using an [event callback parameter (`EventCallback`/`EventCallback<T>`)](xref:blazor/components/event-handling#eventcallback) with `@bind:after` isn't supported. Instead, pass a method that returns an <xref:System.Action> or <xref:System.Threading.Tasks.Task> to `@bind:after`.

Expand Down
15 changes: 0 additions & 15 deletions aspnetcore/blazor/components/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -1843,8 +1843,6 @@ In the preceding code, the CSS selector, `#app`, indicates that the `App` compon

MVC and Razor Pages apps can also use the [Component Tag Helper](xref:Microsoft.AspNetCore.Mvc.TagHelpers.ComponentTagHelper) to register statically-rendered Blazor WebAssembly root components:

:::moniker range=">= aspnetcore-6.0"

```cshtml
<component type="typeof(App)" render-mode="WebAssemblyPrerendered" />
```
Expand All @@ -1853,22 +1851,9 @@ Statically-rendered components can only be added to the app. They can't be remov

For more information, see the following resources:

:::moniker-end

:::moniker range=">= aspnetcore-8.0"

* <xref:mvc/views/tag-helpers/builtin-th/component-tag-helper>
* <xref:blazor/components/integration>

:::moniker-end

:::moniker range=">= aspnetcore-6.0 < aspnetcore-8.0"

* <xref:mvc/views/tag-helpers/builtin-th/component-tag-helper>
* <xref:blazor/components/prerendering-and-integration>

:::moniker-end

<!--Reference links in article-->
[1]: <xref:mvc/views/razor#code>
[2]: <xref:mvc/views/razor#using>
Expand Down
3,201 changes: 2,816 additions & 385 deletions aspnetcore/blazor/components/integration.md

Large diffs are not rendered by default.

10 changes: 0 additions & 10 deletions aspnetcore/blazor/components/layouts.md
Original file line number Diff line number Diff line change
Expand Up @@ -385,18 +385,8 @@ The following rendered HTML markup is produced by the preceding nested layout. E

## Share a Razor Pages layout with integrated components

:::moniker range=">= aspnetcore-8.0"

When routable components are integrated into a Razor Pages app, the app's shared layout can be used with the components. For more information, see <xref:blazor/components/integration>.

:::moniker-end

:::moniker range="< aspnetcore-8.0"

When routable components are integrated into a Razor Pages app, the app's shared layout can be used with the components. For more information, see <xref:blazor/components/prerendering-and-integration>.

:::moniker-end

:::moniker range=">= aspnetcore-8.0"

## Sections
Expand Down
4 changes: 2 additions & 2 deletions aspnetcore/blazor/components/lifecycle.md
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,7 @@ To prevent developer code in <xref:Microsoft.AspNetCore.Components.ComponentBase

:::moniker range="< aspnetcore-8.0"

To prevent developer code in <xref:Microsoft.AspNetCore.Components.ComponentBase.OnInitializedAsync%2A> from running twice when prerendering, see the [Stateful reconnection after prerendering](#stateful-reconnection-after-prerendering) section. Although the content in the section focuses on Blazor Server and stateful SignalR *reconnection*, the scenario for prerendering in hosted Blazor WebAssembly solutions (<xref:Microsoft.AspNetCore.Mvc.Rendering.RenderMode.WebAssemblyPrerendered>) involves similar conditions and approaches to prevent executing developer code twice. To preserve state during the execution of initialization code while prerendering, see <xref:blazor/components/prerendering-and-integration#persist-prerendered-state>.
To prevent developer code in <xref:Microsoft.AspNetCore.Components.ComponentBase.OnInitializedAsync%2A> from running twice when prerendering, see the [Stateful reconnection after prerendering](#stateful-reconnection-after-prerendering) section. Although the content in the section focuses on Blazor Server and stateful SignalR *reconnection*, the scenario for prerendering in hosted Blazor WebAssembly solutions (<xref:Microsoft.AspNetCore.Mvc.Rendering.RenderMode.WebAssemblyPrerendered>) involves similar conditions and approaches to prevent executing developer code twice. To preserve state during the execution of initialization code while prerendering, see <xref:blazor/components/integration#persist-prerendered-state>.

:::moniker-end

Expand Down Expand Up @@ -612,7 +612,7 @@ The content in this section focuses on Blazor Web Apps and stateful SignalR *rec

:::moniker range="< aspnetcore-8.0"

Although the content in this section focuses on Blazor Server and stateful SignalR *reconnection*, the scenario for prerendering in hosted Blazor WebAssembly solutions (<xref:Microsoft.AspNetCore.Mvc.Rendering.RenderMode.WebAssemblyPrerendered>) involves similar conditions and approaches to prevent executing developer code twice. To preserve state during the execution of initialization code while prerendering, see <xref:blazor/components/prerendering-and-integration#persist-prerendered-state>.
Although the content in this section focuses on Blazor Server and stateful SignalR *reconnection*, the scenario for prerendering in hosted Blazor WebAssembly solutions (<xref:Microsoft.AspNetCore.Mvc.Rendering.RenderMode.WebAssemblyPrerendered>) involves similar conditions and approaches to prevent executing developer code twice. To preserve state during the execution of initialization code while prerendering, see <xref:blazor/components/integration#persist-prerendered-state>.

:::moniker-end

Expand Down
Loading
Loading