Simple, small, reliable and pure javascript scroll library with 0 dependencies.
scrollToTarget(selector, speed, offset)
A valid dom selector
Required
Scroll duration in milliseconds
Optional, defaults to: 300 {ms}
Space in pixels between the target element and the window top.
Optional, defaults to: 0 {pixels}
scrollToTarget('#valid-dom-element-selector', 500, 80)
The code above will scroll the page to the #valid-dom-element-selector with 80px gutter and a duration of 500ms.
IE8+, iOS Safari 3.2+, MS Edge, Chrome 4+, Firefox 3.5+
MIT