canton7 / PropertyChanged.SourceGenerator

Powerful INotifyPropertyChanged / INotifyPropertyChanging Source Generator, which generates INPC boilerplate for you as part of your build. Supports features such as automatic and manual dependencies between properties, notifications when specific properties change, and more.
MIT License
138 stars 14 forks source link

Unable build with WPF project. #1

Closed Cologler closed 2 years ago

Cologler commented 2 years ago

Keep this issue until the upstream fix.

To Reproduce

  1. Create a new WPF project;
  2. Install PropertyChanged.SourceGenerator from NuGet;
  3. Add using PropertyChanged.SourceGenerator;
  4. Build failed.

Additional Info

Add <IncludePackageReferencesDuringMarkupCompilation>true</IncludePackageReferencesDuringMarkupCompilation> to .csproj file worked for me.

see https://github.com/dotnet/wpf/issues/3404.

canton7 commented 2 years ago

Weird, I wonder why I haven't run into that myself yet.

I think I'm right in thinking that this isn't something I can fix on my side -- it's something the consuming project needs to do?