some-react-components / react-scrollchor

A React component for scroll to `#hash` links with smooth animations
ISC License
149 stars 24 forks source link

use requestAnimationFrame instead of setTimeout #21

Closed kambing86 closed 6 years ago

kambing86 commented 6 years ago

is it better to use requestAnimationFrame instead? https://github.com/chrisdickinson/raf

bySabi commented 6 years ago

requestAnimationFrame is better for sure!

PR is welcome 👍

kambing86 commented 6 years ago

check https://github.com/bySabi/react-scrollchor/pull/22

bySabi commented 6 years ago

merged!

Thanks a ton for contrib 👍