optionalFromJson method Null safety

D? optionalFromJson(
  1. J? value
)

Implementation

D? optionalFromJson(J? value) =>
    value == null ? null : mandatoryFromJson(value);