Created
March 20, 2017 12:01
-
-
Save marckrenn/ec5c26603122ba135d030912b4e2d92b to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{QueryInterface} = require 'QueryInterface' | |
bgColor = new QueryInterface | |
key: "bgColor" # key used in address bar: ?bgColor=28affa | |
default: "28affa" # fallback / initial color = 'Framer blue' (hex color) | |
Canvas.backgroundColor = bgColor.value | |
window.addEventListener 'click', -> | |
bgColor.value = Canvas.backgroundColor = Utils.randomColor().toHex() | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment