Episode

Customizing property names & values when reading .NET objects as JSON

with Matt Soucoup, James Montemagno

By default, property names and dictionary keys are unchanged in the JSON output, including case. Enum values are represented as numbers. And properties are serialized in the order they're defined. However, you can customize these behaviors by customizing property names and dictionary keys in the JSON output, including case and the order they're defined. James and Matt break it all down.

Chapters

  • 00:00 - Introduction JSON properties
  • 01:30 - Customizing property names
  • 04:00 - Property naming policies and casing
  • 09:45 - Custom naming policies
  • 11:45 - Sorting JSON properties
  • 14:40 - Wrap-up

.NET