Tarmil / FSharp.SystemTextJson

System.Text.Json extensions for F# types
MIT License
329 stars 45 forks source link

Allow using single-case unions as dictionary keys #161

Closed Tarmil closed 1 year ago

Tarmil commented 1 year ago

For all cases where we allow single-case unions as map keys, we should also allow them as dictionary keys.

Dictionaries are handled directly by System.Text.Json, but since .NET 6 we can customize its handling of keys using JsonConverter.Write/ReadAsPropertyName.

Tarmil commented 1 year ago

Released in v1.2.