fromJson method

  1. @override
Axis? fromJson(
  1. String? json
)
override

Implementation

@override
Axis? fromJson(String? json) {
  if (json == null) return null;

  switch (json) {
    case 'horizontal':
      return Axis.horizontal;

    case 'vertical':
      return Axis.vertical;
  }

  throw 'Unsuported_Json_Value';
}