+ 1
I can not understand the reason. Gives an error message. What's wrong?
When I select the size, I get an error, I can not understand why. https://code.sololearn.com/Wku29nGV13pc/?ref=app
2 Answers
+ 2
You never made an element with the ID showWidth
+ 2
<div>
<button onclick='clearCanvas()'>CLEAR</button>
<button id='ERASER'
onclick='changeColor("white")'
ontouchstart='changeColor("while")'
onclick='clearCanvas()'>ERASER</button>
<div>Width:
<span id="showWidth">40</div>
</span></div>