rows property
Rows of the grid.
An iterable of rows, where each row is an iterable representing the columns of that particular row, in the order they appear in the grid; the first row is the top-most row, and the last row is the bottom-most row.
Example
final grid = Grid.fromRows(
[
[Tile.wall, Tile.wall, Tile.wall],
[Tile.wall, Tile.floor, Tile.wall],
],
fill: Tile.wall,
);
print(grid.rows.first); // [Tile.wall, Tile.wall, Tile.wall]
print(grid.rows.last); // [Tile.wall, Tile.floor, Tile.wall]
Implementation
Iterable<Iterable<E>> get rows => _Rows(this);