I tried to apply the sample form this post to get an top-bar shrinking on scroll:
But I can not get it working.
So to simply-fie things I used the js in a codepen test to find out how it works. But it does not work! What's wrong with my sample and why is the sample form the forum post not working? I have the js in the app.js file and have the html <div class="top-bar large"> in my page. ?
this is my test in codepen instead of resizing I just want the color to change: