JSFiddle - React, Tailwind, and code Playground

by Amar Nyayapati

HTML

<style>
    body {
        margin: 0px;
        padding: 0px;
    }
    #myCanvas {
        border: 1px solid #9C9898;
    }
</style>
<script>
    window.onload = function() {
        var canvas = document.getElementById("myCanvas");
        var context = canvas.getContext("2d");
        context.beginPath();
        context.lineWidth = 5;
        context.moveTo(170, 150);
        context.lineTo(270, 110);
        context.lineTo(370, 150);
        context.lineJoin = "round";
        context.stroke(); 
    }        
</script>
<body>
    <canvas id="myCanvas" width="578" height="200"></canvas>
</body>