Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Somewhat off topic:

This page has a beautiful javascript effect if you scroll. The index follows the page smoothly and highlights the displayed section. Does anyone know if this is a public library/function?



You should look into jquery waypoints --> http://imakewebthings.github.com/jquery-waypoints/

I use it on my blog to change how social buttons behave once you scroll past a certain point.


That is so amazingly sexy. Thank you :D

These sticky elements seem to scroll with the page (or stick?) much more smoothly than I've seen on other pages. Are there crappy versions out there or could I just be experiencing a newer browser optimization?


It's a simple trick. Instead of using JavaScript to stick them on the page, you change their positioning to fixed when they hit the window's edge. Then the browser takes care of the rest.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: