JavaScript:
`var id = document.getElementById('canvas');
var ctx = id.getContext('2d');
!((_rAF) => {
function render() {
window.requestAnimationFrame = (cb) => {
_rAF((t) => {
ctx.beginPath();
ctx.moveTo(75, 50);
ctx.lineTo(100, 75);
ctx.lineTo(100, 50);
ctx.fillStyle = "#643A9C";
ctx.fill();
cb(t);
render();
})
}
}
})(window.requestAnimationFrame);