I\'m making a JS/PHP plugin for distribution. I want it to be as easy to install as this:
Testing my Plugin
You don't resize the document but the window. This works :
window.addEventListener("resize", function(){console.log('resize!')}, true);