Skip to content

Instantly share code, notes, and snippets.

@quirkey
Created September 15, 2009 23:22
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 quirkey/187753 to your computer and use it in GitHub Desktop.
Save quirkey/187753 to your computer and use it in GitHub Desktop.
;(function($) {
$.fn.soon = function(what, when) {
var $this, args;
if (typeof when == "undefined") when = 5000;
args = $.makeArray(arguments).slice(2);
$this = $(this);
setTimeout(function() {
$this[what].apply($this,args);
}, when);
return $this;
};
})(jQuery);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment