Skip to content

Instantly share code, notes, and snippets.

@beshur
Created February 3, 2014 10:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save beshur/8781777 to your computer and use it in GitHub Desktop.
Save beshur/8781777 to your computer and use it in GitHub Desktop.
javascript jQueryUI Resizable window resize bug fix (jQuery)
// fix jqueryui resizable bug:
//
// jqueryui resizable on 'resize' event invokes
// window.resize event, which maybe unwanted behaviour sometimes
//
window.onresize = function(event) {
if (typeof event.target.getAttribute === 'function')
return;
};
// or jQuery way, with shortened event
$(window).resize(function(e) {
if (typeof e.target.getAttribute === 'function') return;
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment