JSFiddle - React, Tailwind, and code Playground
HTML
<canvas></canvas>
JavaScript
var ctx = document.querySelector('canvas').getContext('2d');
ctx.fillStyle = 'green';
ctx.fillRect(5, 5, 170, 170);
ctx.fillStyle = 'red';
ctx.fillRect(10, 10, 70, 70);