Adds a class to elements when scrolled into view.
Just include onscrollclass.min.js in your page:
<script src="onscrollclass.min.js"></script>
Define a class that gets assigned for elements that are scrolled into view using data-onscrollclass
:
<div class="foo" data-onscrollclass="bar"></div>
Now, add transitions, animations, etc. in your CSS class .bar
.