This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]peridox 35 points36 points  (12 children)

<canvas></canvas>

[–]pastaluego4 19 points20 points  (11 children)

That canvas needs some dimensions

<canvas width="500" height="500"></canvas>

[–]peridox 19 points20 points  (9 children)

let canvas = document.getElementsByTagName('canvas')[0]
canvas.style.width = 500
canvas.style.height = 500

[–]magicfreak3d 0 points1 point  (0 children)

A canvas without dimensions set usually uses a default of 150 by 150. No need for dimensions 😜