jasonkarns
5/7/2015 - 6:31 PM

requirebin sketch

requirebin sketch

<!-- contents of this file will be placed inside the <head> -->
<!-- contents of this file will be placed inside the <body> -->
{
  "name": "requirebin-sketch",
  "version": "1.0.0",
  "dependencies": {
    "domready": "1.0.8"
  }
}
require=function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s}({domready:[function(require,module,exports){!function(name,definition){if(typeof module!="undefined")module.exports=definition();else if(typeof define=="function"&&typeof define.amd=="object")define(definition);else this[name]=definition()}("domready",function(){var fns=[],listener,doc=document,hack=doc.documentElement.doScroll,domContentLoaded="DOMContentLoaded",loaded=(hack?/^loaded|^c/:/^loaded|^i|^c/).test(doc.readyState);if(!loaded)doc.addEventListener(domContentLoaded,listener=function(){doc.removeEventListener(domContentLoaded,listener);loaded=1;while(listener=fns.shift())listener()});return function(fn){loaded?setTimeout(fn,0):fns.push(fn)}})},{}]},{},[]);var d=require("domready");d(function(){alert("boo")});
// require() some stuff from npm (like you were using browserify)
// and then hit Run Code to run it on the right
var d = require('domready');

d(function(){
  alert("boo")
});