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

Implement PropertyChanged.Fody #3

Closed
sebleg opened this issue May 4, 2019 · 1 comment
Closed

Implement PropertyChanged.Fody #3

sebleg opened this issue May 4, 2019 · 1 comment
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@sebleg
Copy link

sebleg commented May 4, 2019

To save many code lines and to get more overview in the view model classes it would be a good solution to add the NuGet package PropertyChanged.Fody in the project.

It implements the OnPropertyChanged() statement to all classes that implement INotifyPropertyChanged. See on GitHub: https://github.com/Fody/PropertyChanged

For example the following code lines in MainViewModel.cs

public bool IsFlyoutOpen
{
  get { return _isFlyoutOpen; }
  set
  {
    _isFlyoutOpen = value;
    OnPropertyChanged();
  }
}

could then look like this (with same behaviour):

public bool IsFlyoutOpen {get; set;}

@sebleg sebleg added the enhancement New feature or request label May 4, 2019
@JustForFunDeveloper JustForFunDeveloper self-assigned this May 5, 2019
@JustForFunDeveloper JustForFunDeveloper added this to the v0.1.3.0-beta milestone May 5, 2019
@JustForFunDeveloper
Copy link
Owner

Thank you very much for this suggestion!

This looks pretty neat, i already thought that the HomeViewModel is quite code heavy.
So this will clean it up a bit.

I'll definitly try to add this in the next release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants