Vidyalelo
HTML · Q41

HTML5

Programming · HTML · question 41

Q41

To draw on the canvas, authors must first obtain a reference to a context using the ______________ method of the canvas interface element.

A.
getData
B.
toDataURL
C.
getContext
Answer
D.
none of the mentioned

Answer: Option C

Solution

Answer: Option C
Solution:
contextType is a DOMString containing the context identifier defining the drawing context associated to the canvas.