Focusin/focusout polyfill for Firefox based on this gist by @nuxodin. Addresses this bug in Firefox.
npm install focusin
Or, just copy focusin.min.js
into your project if you don't use browserify. The minified script automatically runs the polyfill
method, so all you have to do is include it.
focusin is a polyfill, so you don't need to assign it to a variable, just require it and call the polyfill
method. Obviously meant for browser environments and not Node.js. If you only require the module no code will be attached to the window.
require('focusin').polyfill()
Contributions welcome! Please read the contributing guidelines first.
Project template generated with module-init.