Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Demo: you don't need to manually implement INotifyPropertyChanged #21

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

jsauve
Copy link

@jsauve jsauve commented Dec 30, 2020

Demonstrating how you don't need to manually implement INotifyPropertyChanged. Use the PropertyChanged.Fody nuget to make your life easier. Get rid of unneeded boilerplate and still have the power of property-changed notifications.
https://github.com/Fody/PropertyChanged

See BaseViewModel.cs for the only code changes I made.

The Reactive UI project also has something similar that it injects the code for property-changed notifications at runtime. I just prefer PropertyChanged.Fody because I'm not big on the Reactive UI stuff.

Anyway, hope you find this useful. I use PropertyChanged.Fody in all my projects.

…yChanged. Use the PropertyChanged.Fody nuget to make your life easier.
@UdaraAlwis
Copy link
Owner

UdaraAlwis commented Dec 31, 2020

@jsauve Nice work mate. Appreciate it. I'm thinking whether to merge this here or create a new project solution to demonstrate the use of Fody with Xamarin.Forms. :S

@jsauve
Copy link
Author

jsauve commented Jan 5, 2021

No worries! Demoing PropertyChanged.Fody isn't really specific to your solution here. I was actually borrowing your navigation override stuff to handle cancelation tokens for long-running network calls in a cross-platform way. Much appreciated! I just figured I'd share the knowledge about PropertyChanged.Fody so you can avoid having to write so much boilerplate property code in the future. 🍻

@fgonc124
Copy link

HI

When I run your demo, it always activates the keyboard. Is there any trick? Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants