Friday , October 19 2018
Home / HTML / What is canvas in HTML 5?

What is canvas in HTML 5?

Canvas is an HTML area on which you can draw graphics.

Get access to canvas area

To draw on the canvas area we need to first get reference of the context section. Below is the code for canvas section.

Draw the graphic

Now once you have access to the context object we can start drawing on the context. So first call the “move” method and start from a point , use line method and draw the line and then apply stroke over it.

About admin

Check Also

What is HTML?

HTML is a computer language devised to allow website creation. These websites can then be ...

Leave a Reply