Interface SerializationOptions

Options that can be passed to the serialization/deserialization functions and change the behavior in runtime (not embedded in JIT).

Hierarchy

  • SerializationOptions

Properties

groups?: string[]

Which groups to include. If a property is not assigned to a given group, it will be excluded. Use an empty array to include only non-grouped properties.

groupsExclude?: string[]

Which groups to exclude. If a property is assigned to at least one given group, it will be excluded. Basically the opposite of groups, but you can combine both. Use an empty array to exclude only non-grouped properties.

loosely?: boolean

Allows more loosely data for certain types. e.g.

  • '1', '0', 'true', 'false' will be converted to true|false for boolean type.
  • '1' will be converted to number for number type.
  • 1 will be converted to string for string type.

This will activate all registered type guards with negative specifically.

This is enabled by default.

Generated using TypeDoc