Workshop › 15 Puzzle › Step 3 of 27
Our first drawing: the whole canvas gets a dark brown-grey, the table the puzzle lies on.
```js
ctx.fillStyle = '#292524'
ctx.fillRect(0, 0, canvas.width, canvas.height)
```ctx.fillStyle = '#292524' picks the fill color.ctx.fillRect(x, y, width, height) fills a rectangle. 0, 0 is the top-left corner; canvas.width and
canvas.height (400 and 460) make it cover everything.Between the reset function and the reset() call at the bottom, write the two lines, with empty lines around them.
Skills: Drawing on a canvas
← The canvas and the pen A function that draws →