SkillAgentSearch skills...

Bertuzzi.MAUI.EventAggregator

⚙️EventAggregator provides multicast publish/subscribe functionality

Install / Use

/learn @TBertuzzi/Bertuzzi.MAUI.EventAggregator
About this skill

Quality Score

0/100

Supported Platforms

Universal

README

Bertuzzi.MAUI.EventAggregator

The EventAggregator provides multicast publish/subscribe functionality. This means there can be multiple publishers that raise the same event and there can be multiple subscribers listening to the same event.

This is the component, works on iOS, Android and UWP.

NuGet

|Name|Info| | ------------------- | :------------------: | |Bertuzzi.MAUI.EventAggregator|NuGet|

Platform Support*

Bertuzzi.MAUI.EventAggregator is a MAUI library.

Setup / Usage

Does not require additional configuration. Just install the package in the shared project and use.

Sample

Create a Sample Message

    public class TextMessage
    {
        public string Text { get; set; }
    }

Register Handler to listen to the event


  private void TextHandler(
    TextMessage message)
        {
            Text = message.Text;
        }
        
   //Register Event Handler
            EventAggregator.Instance.RegisterHandler<TextMessage>(
       TextHandler);

Send Message

   //Register Event
          
EventAggregator.Instance.SendMessage(TextMessage);

The complete example can be downloaded here: https://github.com/TBertuzzi/Bertuzzi.MAUI.EventAggregator/tree/master/MAUIEventAggregatorSample

BaseViewModel and Commands used of : https://github.com/jamesmontemagno/mvvm-helpers/tree/master/MvvmHelpers

Based on my package : https://github.com/TBertuzzi/Xamarin.Forms.EventAggregator

Related Skills

View on GitHub
GitHub Stars6
CategoryDevelopment
Updated4mo ago
Forks1

Languages

C#

Security Score

72/100

Audited on Nov 10, 2025

No findings