Caleb Bertrand
Caleb Bertrand

Reputation: 414

Using jquery animate properly?

I'm not a total wizard at jQuery, so I just need some clarification: shouldn't the code below be free of any errors? If you look at the codepen, you'll see that it throws an 'unexpected identifier' at line 9.

$('.tester').animate({
      opacity: 1,
        },
        {
              duration: 500,
            progress: function(a, p, c ) {
            //whatever
            }
            complete: function() {
          //whatever
        }
        });

Upvotes: 0

Views: 31

Answers (1)

Jarek Kulikowski
Jarek Kulikowski

Reputation: 1389

You are missing a comma before complete: function().

Upvotes: 1

Related Questions