I have a problem with the canvas drawing, this is my code follow W3school to draw a clock, but when i coded on my website, it's drawing the wrong way. I don't know why....
var canvas = document.getElementById("canvas");
var ctx = canvas.getContext("2d");
var radius = 75;
ctx.translate(radius, radius);
radius = radius * 0.90
drawClock();
function drawClock() {
ctx.arc(0, 0, radius, 0, 2 * Math.PI);
ctx.fillStyle = "white";
ctx.fill();
}
#canvas {
width: 15vw;
height: 15vw;
background-color: red;
position: fixed;
left: 80%;
top: 50px;
}
<canvas id="canvas"></canvas>