JS1k: The JavaScript code golfing competition

2018 - The Volatile Coin Mine

Home   Rules   Demos   Submit Mailing list  |  Update demo meta data  |  The /r/js1k subreddit JS1k, the yearly JS code golfing competition

Competition rules 2018


The rules are simple:



But just to be sure:

  1. Size limit is 1024 bytes

    A byte is 8 bits. The count could be unequal to the character count due to various encoding schemes. The server will enforce this.
  2. No externals

    Use common sense. getUserMedia is NOT allowed. File inputs must be optional, not mandatory to run the demo. Otherwise, when in doubt, just ask me. If something obviously requires external input to display its functionality demo I will notify you and reject it.
  3. Must work as is in the provided shim

    There is one shim for all demos. It features the following. ("optional" means you can configure it when submitting your demo)

    1. Exposes the canvas in window.a, the body in window.b, the canvas 2d or 3d context in window.c, and the document in window.d
    2. the canvas is optional and fullscreen by default, configurable in submit form
    3. WebGL shim (same as last year) and 3d context are also configurable
    4. calling the demo restart function (top.reload()), is exactly the same as pressing the reload button and reinitialize the iframe
    5. normalization of vendor prefixed API's (please notify me if something needs unprefixing/normalization)
  4. May not escape the iframe

    Don't touch top or parent. Exception: top.reload(). You're allowed to adjust the url hash as long as you don't reload the page.
  5. Must be received before February 28th, 23:59 GMT

    Form submission automatically closes February 28th 2018, midnight GMT (that's London, UK time).
  6. Must work in at least two common desktop browsers

    Two of: Chromium, Firefox, Edge, and Safari. And at least Chromium or Firefox so I can check under linux. Mobile support is nice but not required.

    ES6+ is allowed for as far as browsers support it.

    Versions: Chrome=55, Firefox=51, Edge=38, Safari=10.

    The emoji's in linux are black and white! I make the thumbs in linux.
  7. Theme is optional

    It is only a suggestion for inspiration. If you don't like the theme or had something else in mind by all means go for it.
  8. When in doubt: I decide

    And if it concerns an interpretation of the rules I will consult the judges on a verdict.