Soenneker.Blazor.Extensions.EventCallback 11.0.477

Prefix Reserved
dotnet add package Soenneker.Blazor.Extensions.EventCallback --version 11.0.477
                    
NuGet\Install-Package Soenneker.Blazor.Extensions.EventCallback -Version 11.0.477
                    
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.Blazor.Extensions.EventCallback" Version="11.0.477" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Soenneker.Blazor.Extensions.EventCallback" Version="11.0.477" />
                    
Directory.Packages.props
<PackageReference Include="Soenneker.Blazor.Extensions.EventCallback" />
                    
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.Blazor.Extensions.EventCallback --version 11.0.477
                    
#r "nuget: Soenneker.Blazor.Extensions.EventCallback, 11.0.477"
                    
#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.Blazor.Extensions.EventCallback@11.0.477
                    
#: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.Blazor.Extensions.EventCallback&version=11.0.477
                    
Install as a Cake Addin
#tool nuget:?package=Soenneker.Blazor.Extensions.EventCallback&version=11.0.477
                    
Install as a Cake Tool

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

Soenneker.Blazor.Extensions.EventCallback

Small Blazor extensions that invoke an EventCallback only when its consumer assigned a delegate.

Installation

dotnet add package Soenneker.Blazor.Extensions.EventCallback

Usage

The extension removes repeated HasDelegate checks from reusable components:

@using Soenneker.Blazor.Extensions.EventCallback

<button @onclick="Save">Save</button>

@code {
    [Parameter]
    public EventCallback<Order> OnSaved { get; set; }

    private async Task Save()
    {
        Order order = await SaveOrder();
        await OnSaved.InvokeIfHasDelegate(order);
    }
}

The non-generic overload works the same way:

[Parameter]
public EventCallback OnClosed { get; set; }

await OnClosed.InvokeIfHasDelegate();

When no delegate is assigned, both overloads return Task.CompletedTask. When a delegate is assigned, invocation follows normal Blazor EventCallback.InvokeAsync behavior, including renderer dispatch and exception propagation. Await the returned task when subsequent work depends on the callback completing.

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 (11)

Showing the top 5 NuGet packages that depend on Soenneker.Blazor.Extensions.EventCallback:

Package Downloads
Soenneker.Blazor.TomSelect

A Blazor interop library for the select user control library, Tom Select

Soenneker.Blazor.Turnstile

Renders a Cloudflare Turnstile widget in Blazor and exposes its token and lifecycle events.

Soenneker.Blazor.Stripe.Elements

A modular, strongly-typed Blazor library for Stripe Elements

Soenneker.Blazor.Chatwoot

A Blazor interop library for Chatwoot, the open-source customer engagement suite.

Soenneker.Blazor.Floating.Tooltips

A Blazor interop library using the modern library, floating-ui, for tooltips

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
11.0.477 2,175 11/18/2026
11.0.476 7,971 11/11/2026
11.0.475 555 11/10/2026
11.0.474 11,222 10/26/2026
4.0.473 912 10/25/2026
4.0.472 7,714 10/14/2026
4.0.471 572 10/14/2026
4.0.470 108 10/14/2026
4.0.465 1,093 10/12/2026
4.0.464 1,447 10/12/2026
4.0.463 1,929 10/11/2026
4.0.462 14,178 9/24/2026
4.0.461 5,612 9/15/2026
4.0.460 5,501 9/12/2026
4.0.459 3,236 9/8/2026
4.0.458 12,634 8/29/2026
4.0.457 277 8/29/2026
4.0.456 9,376 8/11/2026
4.0.455 10,311 7/27/2026
4.0.454 11,139 7/16/2026
Loading failed

Configure .NET CI defaults and daily source scans