title: fade in each div when it comes into view
body: <p>I know how to fade in a div when it comes into view... My current function is doing that. The issue is that when the first div comes into view, all the divs fade in. However I want each div to fade in when each one comes into view. This is my current function:</p>
  
  <pre><code>$(window).scroll(function() {
      var mywindow = $(window);
      var mypos = mywindow.scrollTop();
  
      $(".textDiv").each(function() {
        var currentDiv = $(this);
        if (mypos &gt; $(currentDiv).offset()["top"] - mywindow.height()) {
          $(currentDiv).fadeIn(500);
        };
      });
  
    });
  </code></pre>