JSFiddle - React, Tailwind, and code Playground

by Muhammad Nugroho

HTML

<html>


<head>
  <title>Paranoid — Shiny Demos</title>
  <meta charset="utf-8">
  <meta name="viewport" content="width=372, user-scalable=no">
  <link rel="stylesheet" href="styles/style.css">
  <link rel="stylesheet" href="/styles/panel.css">
</head>
<body>
  <div id="container">
    <h1>Paranoid 0.4</h1>
    <canvas id="bouncy" width="360" height="378"></canvas>
    <div id="controls">
      <h2>Instructions</h2>
      <p>To control the paddle, use the mouse, touchscreen or keyboard.</p>
      <dl>
        <dt>(a)</dt>
        <dd>toggle autopilot</dd>
        <dt>(&lt;)</dt>
        <dd>move left</dd>
        <dt>(>)</dt>
        <dd>move right</dd>
      </dl>
    </div>
    <p id="autopilot">Autopilot</p>
  </div>
  <script src="/scripts/modernizr.js"></script>
  <script src="/scripts/panel.js"></script>
  <script src="scripts/options.js"></script>
  <script src="scripts/PxLoader.js"></script>
  <script src="scripts/PxLoaderImage.js"></script>
  <script src="scripts/script.js"></script>


<body>

<script>
/**
 * PixelLab Resource Loader
 * Loads resources while providing progress updates.
 */
function PxLoader(settings) {

    // merge settings with defaults
    settings = settings || {};

    // how frequently we poll resources for progress
    if (settings.statusInterval === null) {
        settings.statusInterval = 5000; // every 5 seconds by default
    }

    // delay before logging since last progress change
    if (settings.loggingDelay === null) {
        settings.loggingDelay = 20 * 1000; // log stragglers after 20 secs
    }

    // stop waiting if no progress has been made in the moving time window
    if (settings.noProgressTimeout === null) {
        settings.noProgressTimeout = Infinity; // do not stop waiting by default
    }

    var entries = [], // holds resources to be loaded with their status
        progressListeners = [],
        timeStarted,
        progressChanged = +new Date();

    /**
     * The status of a resource
     * @enum...