Welcome to The Onepager
The code used was borrowed from CSS-Tricks Smooth Scrolling by Chris Coyier. Thanks!
How to use it?
Just copy the code and paste it in your wp-footer hook, then add your IDs and your links as suggested by the w3c, that’s it!