JSFiddle - React, Tailwind, and code Playground
by alexvestin
HTML
<canvas id="canvas"></canvas>
JavaScript
const canvas = document.getElementById("canvas");
const ctx = canvas.getContext("2d");
ctx.strokeStyle = "red";
ctx.beginPath();
ctx.lineTo(100,100);
ctx.fill();
ctx.fillStyle = "red";
//ctx.fillRect(0,0,100,100);