Generator that returns rectangles for each cell in a grid
import { Drawing } from 'visuals.js'const rects = [...Grids.asRectangles(grid)];Drawing.rect(ctx, rects, { strokeStyle: `silver`}); Copy
import { Drawing } from 'visuals.js'const rects = [...Grids.asRectangles(grid)];Drawing.rect(ctx, rects, { strokeStyle: `silver`});
Generator that returns rectangles for each cell in a grid