You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
#47: Add Skippable<'T> to represent values that can be omitted from the serialization of a record or a union with NamedFields. This is particularly useful with Skippable<'T option> (or voption) to represent a field that can be omitted, null, or have a proper value.
typeR={ x:Skippable<int option>}{ x = Skip }// Serialized as: {}{ x = Include None }// Serialized as: {"x":null}{ x = Include (Some 42)}// Serialized as: {"x":42}
Also add a Skippable module with standard functions: map, filter, etc. Implementation largely based on @cmeeren's JsonSkippable which provides the same functionality for Newtonsoft.Json.
#51: When the type K is a single-case union wrapping a string, serialize Map<K, V> into a JSON object, like Map<string, V>.
Allow OR-ing a base JsonUnionEncoding (AdjacentTag, InternalTag, ExternalTag or Untagged) with Default to use the default extra options (UnwrapOption ||| UnwrapSingleCaseUnions).