Created
October 2, 2012 06:45
-
-
Save raybellis/3816885 to your computer and use it in GitHub Desktop.
A jQuery plugin to allow any function to be queued (default 'fx' queue only)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function($) { | |
$.fn.queued = function() { | |
var self = this; | |
var func = arguments[0]; | |
var args = [].slice.call(arguments, 1); | |
return this.queue(function() { | |
$.fn[func].apply(self, args).dequeue(); | |
}); | |
} | |
}(jQuery)); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment