required property Null safety

bool? required

When true, generated code for fromJson will verify that the source JSON map contains the associated key.

If the key does not exist, a MissingRequiredKeysException exception is thrown.

Note: only the existence of the key is checked. A key with a null value is considered valid.


final bool? required;