Update README.md
This commit is contained in:
committed by
GitHub
parent
62f3ffddc2
commit
1992fdfcaf
@ -301,7 +301,7 @@ var rgbToHex = (r, g, b) =>
|
||||
### Scroll to top
|
||||
|
||||
Get distance from top using `document.documentElement.scrollTop` or `document.body.scrollTop`.
|
||||
Scroll by a fraction of the distance from top. Use `window.requestFrame()` to animate the scrolling.
|
||||
Scroll by a fraction of the distance from top. Use `window.requestAnimationFrame()` to animate the scrolling.
|
||||
|
||||
```js
|
||||
var scrollToTop = _ => {
|
||||
|
||||
Reference in New Issue
Block a user