JSFiddle - React, Tailwind, and code Playground

HTML

<script src="http://cdnjs.cloudflare.com/ajax/libs/pixi.js/1.5.1/pixi.js"></script>
<canvas id="view"></canvas>

JavaScript

init();
function init()
{
    var width = 300;
    var height = 300;
    var canvas = document.getElementById("view");
    var stage = new PIXI.Stage(0x000000);
    var renderer = new PIXI.autoDetectRenderer(width, height, canvas, null, true);
    
    var colors = [0x00FFFF, 0xFF0000, 0x00FF00, 0x0000FF];
    var colorIndex = 0;
    
    var circle = new PIXI.Graphics();
    circle.beginFill(colors[colorIndex]);
    circle.lineStyle(2, 0xFFFFFF);
    circle.drawCircle(60, 60, 30);
    
    stage.addChild(circle);
    renderer.render(stage);
    
    setInterval(update, 1000);
    
    function update()
    {
        colorIndex += 1;
        if (colorIndex >= colors.length) colorIndex = 0;

        circle.clear();        
        circle.beginFill(colors[colorIndex]);
        circle.lineStyle(2, 0xFFFFFF);
        circle.drawCircle(60, 60, 30);
        
        renderer.render(stage);
    }
}