Do not set DataContext or Style using SetCurrentValue

Proprietary

DataContext and Style are inherited through the visual tree, so a value written with SetCurrentValue is discarded as soon as the inherited value changes. Replaces the call with SetValue.

OpenRewrite.Recipes.CSharp.CodeQuality.Wpf.UseSetValueForDataContextAndStyle
mod run . --recipe=OpenRewrite.Recipes.CSharp.CodeQuality.Wpf.UseSetValueForDataContextAndStyle

Install it once, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.