SyntaxFix
Write A Post
Hire A Developer
Questions
You can write: [JsonProperty("property_name",DefaultValueHandling = DefaultValueHandling.Ignore)]
[JsonProperty("property_name",DefaultValueHandling = DefaultValueHandling.Ignore)]
It also takes care of not serializing properties with default values (not only null). It can be useful for enums for example.