JsonField<T> constructor

JsonField<T>(
  1. String name, {
  2. String? helper,
  3. bool isRequired = false,
  4. T? defaultValue,
})

Implementation

JsonField(
  this.name, {
  this.helper,
  this.isRequired = false,
  T? defaultValue,
}) {
  type = T;
  if (defaultValue != null) {
    this.defaultValue = defaultValue;
  }
}