PropertyChanged.SourceGenerator
PropertyChanged
Our great sponsors
PropertyChanged.SourceGenerator | PropertyChanged | |
---|---|---|
2 | 14 | |
123 | 1,831 | |
- | 0.9% | |
4.6 | 8.5 | |
about 1 year ago | 5 days ago | |
C# | C# | |
MIT License | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
PropertyChanged.SourceGenerator
-
Is it just me, or is WPF just harder to work with than WinForms?
Now the ugly part - you need to implement INotifyPropertyChanged. It can be done either manually, or automated with this or this
-
Alternative to Fody.PropertyChanged?
There are another ones: - PropertyChanged.SourceGenerator - NotifyPropertyChangedGenerator - PostSharp.NotifyPropertyChanged
PropertyChanged
-
Window Forms change notification
Add [AddINotifyPropertyChangedInterface] attribute to the class for change notification.
-
What does Realm.Fody do?
All the weaving libraries (also called weavers or addin) using Fody need to have the .Fody suffix, so it's quite easy to recognize them. As an example, if you ever had to implement INotifyPropertyChanged manually in a class with dozens of properties you would probably welcome weaving (and Fody) with open arms. By creating all the plumbing code directly in IL, libraries like PropertyChanged.Fody allows to inject the necessary notification code without the need to modify anything in the original source code.
-
[Library] Call all IEnumerable<T> via a single injected T
You can rewrite auto-props (as used this this lib https://github.com/Fody/PropertyChanged) with Fody.
-
Double programming meme
If you're not familiar with Fody and specifically the PropertyChanged weaver, I highly recommend checking it out: https://github.com/Fody/PropertyChanged
-
Is it just me, or is WPF just harder to work with than WinForms?
Now the ugly part - you need to implement INotifyPropertyChanged. It can be done either manually, or automated with this or this
-
What can be done to make the switch from WinForms to WPF easier?
https://github.com/Fody/PropertyChanged and Android background makes WPF pretty easy. At least the surface level stuff.
-
Automated nameof(Field)
If you really don't want to deal with it ever again, just add this Fody - PropertyChanged NuGet package. Any class that inherits from INotifyPropertyChanged will be updated at compile time to inject in the boilerplate code for handling the property change and you never even need to think about it again. All you need to do is just add plain old properties. The only downside that some people see is that it is not immediately transparent as the change notification code is injected in during compile and is not in source code.
-
We Just Gave $154,999.89 to Open Source Maintainers
And GitHub is the place where employees of billion dollar companies pester unpaid maintainers because they won’t support a 12 year old version of .NET
https://github.com/Fody/PropertyChanged/issues/270#issuecomm...
-
Can anyone give me an example of how they use fody to simplify the Get;Set; with property changed?
If you need more info, check the docs https://github.com/Fody/PropertyChanged
What are some alternatives?
dotnet - .NET Community Toolkit is a collection of helpers and APIs that work for all .NET developers and are agnostic of any specific UI platform. The toolkit is maintained and published by Microsoft, and part of the .NET Foundation.
Prism - Prism is a framework for building loosely coupled, maintainable, and testable XAML applications in WPF, Xamarin Forms, and Uno / Win UI Applications..
NotifyPropertyChangedGenerator - Roslyn Analyzer/Generator for avoid boring boilerplate INotifyPropertyChanged implementation.
ReactiveUI.Fody - C# Fody extension to generate RaisePropertyChange notifications for properties and ObservableAsPropertyHelper properties.
PostSharp.NotifyPropertyChanged - auto-magic INotifyPropertyChanged done right
sentry-symfony - The official Symfony SDK for Sentry (sentry.io)
Tortuga.Shipwright - A trait engine for C#.
sentry-javascript - Official Sentry SDKs for JavaScript
SaneWpf
UWP Community Toolkit - The Windows Community Toolkit is a collection of helpers, extensions, and custom controls. It simplifies and demonstrates common developer tasks building .NET apps with UWP and the Windows App SDK / WinUI 3 for Windows 10 and Windows 11. The toolkit is part of the .NET Foundation.
Avalonia - Develop Desktop, Embedded, Mobile and WebAssembly apps with C# and XAML. The most popular .NET UI client technology
SharpLab - .NET language playground