Cell.fromJson constructor

Cell.fromJson(
  1. Map<String, dynamic> json
)

Implementation

factory Cell.fromJson(Map<String, dynamic> json) => Cell(
  filled: json['filled'] as bool,
  type: json['type'] != null
      ? TetrominoType.values[json['type'] as int]
      : null,
);