title: Fade in body colour depending on class
body: <p>Trying to animate a background in a slider similar to this website - <a href="http://www.legworkstudio.com/" rel="nofollow">http://www.legworkstudio.com/</a></p>
  
  <p>I'm using a plugin called fullpage.js which adds a class "fp-viewing-#" to the body depending on which slide is selected (starting at 0).</p>
  
  <p>I can't seem to figure out why the lines below don't work. I've tried both .animate + .css to do this.</p>
  
  <pre><code>if ($("body").hasClass("fp-viewing-1")) {
      $("body").animate({"background" : "red"}, 2000);
  }
  </code></pre>