Categories

Oct 23, 2019 in HTML

Q:

What is Canvas in HTML5 ? How to write a Canvas ?

1 Answer

Oct 23, 2019

Canvas is a element of HTML5 which uses JavaScript to draw graphics on a web page. A canvas is a rectangular area. Each and every pixel of it can be controlled by us. There are several methods for drawing paths, boxes, circles, characters, and adding images by using canvas.

To add canvas tag to our HTML document we need id, width and height. Below is the example how to write a basic canvas tag to your HTML document.

<canvas id="myFirstCanvas" width="100" height="100"> </canvas>

Click here to read more about HTML
Click here to read more about Insurance

Related questions

Madanswer
Oct 23, 2019 in HTML
Oct 23, 2019 in HTML
Aug 17 in HTML
...