JSFiddle - React, Tailwind, and code Playground

by UlyssesZhan

HTML

<script src="https://pixijs.download/release/pixi.min.js"></script>

JavaScript

window.app = new PIXI.Application({ width: 400, height: 300, hello: true, autoStart: false});
document.body.appendChild(app.view);

const graphics = new PIXI.Graphics();
graphics.x = -10;
graphics.y = 100;
function drawPath() {
	graphics.arc(0, 0, 50, -0.7, 1);
	graphics.lineTo(200, 0);
	graphics.closePath();
}

graphics.lineStyle(10, 0xffff00, 1, 1);
drawPath();
graphics.lineStyle(1, 0xff0000, 1, 1);
drawPath();

app.stage.addChild(graphics);

app.ticker.add(delta => graphics.x += delta)