Skip to content

Instantly share code, notes, and snippets.

@thekarel
Created April 30, 2014 14:15
Show Gist options
  • Save thekarel/11428317 to your computer and use it in GitHub Desktop.
Save thekarel/11428317 to your computer and use it in GitHub Desktop.
var event = new Event('build');
// Listen for the event.
elem.addEventListener('build', function (e) { ... }, false);
// Dispatch the event.
elem.dispatchEvent(event);
@jamtat
Copy link

jamtat commented May 2, 2014

Been wondering how to do this for ages!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment