Skip to content

Instantly share code, notes, and snippets.

@janodvarko
Created July 2, 2014 11:47
Show Gist options
  • Save janodvarko/c98368c880db22dd063a to your computer and use it in GitHub Desktop.
Save janodvarko/c98368c880db22dd063a to your computer and use it in GitHub Desktop.
How to use when API
// This works
frame.addEventListener("load", event => {
// handler
}, true);
// But this doesn't, why?
const { when } = require("sdk/event/utils");
when("load", frame).then(event => {
// handler
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment