Add an easing to jQuery animate() function.

Posted by user348250 on Stack Overflow See other posts from Stack Overflow or by user348250
Published on 2010-05-23T12:03:19Z Indexed on 2010/05/23 12:10 UTC
Read the original article Hit count: 256

Filed under:
|
|
|

Hello!

I'm triying to add an easing function to this code. So I replaced "swing" with "easeInOutQuint" (for example) but it's not working. I'm using jquery 1.4.2 and jquery easing 1.3 downloaded from here (http://gsgd.co.uk/sandbox/jquery/easing/) Any help will be greatly appreciated! Thank you!

$(window).load(function() {
    $('.trigger').click(function() {
      $('.panel').animate({
        width: ['toggle', 'swing'],
        height: ['toggle', 'swing'],
        opacity: 'toggle'
      }, 190, 'linear', function() {
      });
    });

© Stack Overflow or respective owner

Related posts about JavaScript

Related posts about jQuery