Search
The first thing that we need to do when we are creating a line or a custom shape is to tell the canvas that we are beginning a path.
In the example given below, comment out the beginPath() method and see what happens.
beginPath()