This is an add-in for Fody
Converts public fields to public properties
This feature means you can exclude the { get; set; }
on your properties and use fields instead.
See also Fody usage.
Install the Fielder.Fody NuGet package and update the Fody NuGet package:
PM> Install-Package Fody
PM> Install-Package Fielder.Fody
The Install-Package Fody
is required since NuGet always defaults to the oldest, and most buggy, version of any dependency.
Add <Fielder/>
to FodyWeavers.xml
<?xml version="1.0" encoding="utf-8" ?>
<Weavers>
<Fielder/>
</Weavers>
- For all types find all public instance fields with a capitalised first character
- Convert all those fields to properties with the same name
- Find all usages of those fields and point them to the new properties
Cow designed by Anuar Zhumaev from The Noun Project