JSFiddle - React, Tailwind, and code Playground
by Josh Groves
HTML
<script src="https://cdnjs.cloudflare.com/ajax/libs/pixi.js/3.0.8/pixi.js"></script>
JavaScript
<head><script src="pixi-1.js"></script></head><body><script type="text/javascript">
function render() {
var i;
graphics.clear();
for (i = 0; i < 20000; i++) {
graphics.lineStyle(Math.random() * 30, Math.random() * 0xFFFFFF, 1);
graphics.moveTo(Math.random() * width, Math.random() * height);
graphics.lineTo(Math.random() * width, Math.random() * height);
}
renderer.render(stage);
requestAnimationFrame(render);
}
var width = 1000
, height = 1000
, renderer = PIXI.autoDetectRenderer(width, height)
, graphics = new PIXI.Graphics()
, stage = new PIXI.Container();
stage.addChild(graphics);
document.body.appendChild(renderer.view);
render();
</script></body>