Skip to content

Instantly share code, notes, and snippets.

@shaneog
Last active December 14, 2015 16:49
Show Gist options
  • Save shaneog/5118056 to your computer and use it in GitHub Desktop.
Save shaneog/5118056 to your computer and use it in GitHub Desktop.
(function($){
$.fn.fancyToggle = function(){
var myobj = this;
if (myobj.hasClass('in')) {
myobj.removeClass('in');
setTimeout( function() {
myobj.addClass('hide')}
, 100)
} else {
myobj.removeClass('hide');
setTimeout( function() {
myobj.addClass('in')}
, 100)
}
};
})(jQuery);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment