Soenneker.Maui.Blazor.Bridge 11.0.873

Prefix Reserved
dotnet add package Soenneker.Maui.Blazor.Bridge --version 11.0.873
                    
NuGet\Install-Package Soenneker.Maui.Blazor.Bridge -Version 11.0.873
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Soenneker.Maui.Blazor.Bridge" Version="11.0.873" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Soenneker.Maui.Blazor.Bridge" Version="11.0.873" />
                    
Directory.Packages.props
<PackageReference Include="Soenneker.Maui.Blazor.Bridge" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Soenneker.Maui.Blazor.Bridge --version 11.0.873
                    
#r "nuget: Soenneker.Maui.Blazor.Bridge, 11.0.873"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Soenneker.Maui.Blazor.Bridge@11.0.873
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Soenneker.Maui.Blazor.Bridge&version=11.0.873
                    
Install as a Cake Addin
#tool nuget:?package=Soenneker.Maui.Blazor.Bridge&version=11.0.873
                    
Install as a Cake Tool

Soenneker.Maui.Blazor.Bridge

alternate text is missing from this package README image alternate text is missing from this package README image alternate text is missing from this package README image alternate text is missing from this package README image

Positions native .NET MAUI views over matching elements inside a MAUI BlazorWebView.


Features

  • Embed MAUI components directly inside BlazorWebView like HTML elements.
  • Maintain a structured overlay system for native elements.
  • Provides typed and generic bridges for flexible component integration.

Installation

Install the package via NuGet:

dotnet add package Soenneker.Maui.Blazor.Bridge

Register the interop in CreateMauiApp:

public static MauiApp CreateMauiApp()
{
    var builder = MauiApp.CreateBuilder();
    builder.Services.AddMauiBlazorBridgeAsScoped();
}

Layout Setup

To integrate MAUI components within BlazorWebView, modify your MainPage.xaml.
Wrap the BlazorWebView inside a Grid, and include an AbsoluteLayout (OverlayContainer) to host native elements:

<Grid>
    
    <BlazorWebView x:Name="blazorWebView"
                   HostPage="wwwroot/index.html">
        <BlazorWebView.RootComponents>
            <RootComponent Selector="#app" ComponentType="{x:Type local:Routes}" />
        </BlazorWebView.RootComponents>
    </BlazorWebView>

    
    <AbsoluteLayout x:Name="OverlayContainer" BackgroundColor="Transparent" />
</Grid>

This setup ensures that MAUI-native elements overlay correctly within your BlazorWebView.


Usage

To bridge MAUI elements into Blazor, use either:

  • MauiBlazorTypedBridge<T> (Typed binding)
  • MauiBlazorGenericBridge (Generic binding)

Example: Embedding a MauiLabel in Blazor

@using Microsoft.Maui.Controls

@implements IAsyncDisposable

<MauiBlazorTypedBridge @ref="_bridge" TComponent="Label" Component="_label" />

@code {
    Label? _label;
    MauiBlazorTypedBridge<Label>? _bridge;

    protected override void OnInitialized()
    {
        _label = new Label
        { 
            Text = "This is a MAUI Label", 
            BackgroundColor = Colors.Transparent, 
            TextColor = Colors.Black 
        };
    }

    public async ValueTask DisposeAsync()
    {
        if (_bridge != null)
            await _bridge.DisposeAsync();
    }
}

The bridge observes its placeholder element in the browser and keeps the native view aligned beneath it. Dispose the bridge when the Blazor component is removed; disposal unregisters the callback, browser observers, native handlers, and overlay view.

The overlay sits above the web view. Do not set InputTransparent="True" when the native views must receive taps. Areas covered by the overlay can intercept input intended for the underlying web content, so keep native view bounds as small as practical.

MauiBlazorGenericBridge creates a parameterless View type and can apply common or dictionary-supplied public properties. Use the typed bridge when you already own the view instance or need native event handlers.

Product Compatible and additional computed target framework versions.
.NET net11.0 is compatible. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
11.0.873 107 11/19/2026
11.0.872 55 11/19/2026
11.0.870 76 11/18/2026
11.0.868 77 11/18/2026
11.0.867 127 11/16/2026
11.0.865 106 11/16/2026
11.0.864 108 11/16/2026
11.0.862 98 11/15/2026
11.0.860 104 11/15/2026
11.0.858 103 11/15/2026
11.0.856 100 11/14/2026
11.0.855 101 11/14/2026
11.0.854 105 11/14/2026
11.0.853 174 11/12/2026
11.0.852 101 11/12/2026
11.0.850 133 11/11/2026
11.0.848 100 11/11/2026
11.0.846 96 11/11/2026
11.0.845 100 11/11/2026
11.0.844 80 11/10/2026
Loading failed

Update dependency Soenneker.Extensions.Double to 11.0.483 (#1530)