Skip to content

Instantly share code, notes, and snippets.

@bmeck
Created July 30, 2010 04:43
Show Gist options
  • Save bmeck/499910 to your computer and use it in GitHub Desktop.
Save bmeck/499910 to your computer and use it in GitHub Desktop.
script loads via
resources.queue(type="script",url="...",blocks=["script","css"])
holds on script get a +1, holds on css +1
script handled via
resources.on("script")
default handler(stream,data=element,flush)
script.readyState = "loading"
buffer till ready to eval
eval
script.readyState = "complete"
flush
holds on script get a -1, holds on css get a -1
flush can execute things in queue that have holds on there type == 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment