Leverage CommunityToolkit.MVVM
Messenger
#3797
Unanswered
TheCodeTraveler
asked this question in
Ideas
Replies: 1 comment 1 reply
-
Is there potential in the future for Maui to directly use the toolkit's messenger? Also, would the other frameworks you benchmarked against be interested in moving to this implementation? Are there any barriers to something like that happening? (if it is possible to have the most performant messenger with most of the features needed in other frameworks that would be amazing) |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
The CommunityToolkit.MVVM Messenger has been optimized to avoid any allocations and is 100x more efficient than the
Microsoft.Maui.Controls.MessagingCenter
(see Benchmark below).The MVVM Community Toolkit is an open-source library in the .NET Foundation created and maintained by Microsoft Engineering in conjunction with community contributions.
More information can be found in the Microsoft Docs:
https://learn.microsoft.com/dotnet/communitytoolkit/mvvm/messenger
Recommendation: Deprecate
MessagingCenter
I recommend adding the following
[Obsolete]
attribute:Adding the
[Obsolete]
attribute allows for the following scenarios:Microsoft.Maui.Controls MessagingCenter
MessagingCenter
until they move toCommunityToolkit.MVVM
's messengerBenchmark
Benchmark Source
Beta Was this translation helpful? Give feedback.
All reactions