Hey devs 👋
Have you always wanted to know how to get that buttery smooth scroll back to top button!?
Ya don't need another library to achieve this! Get the job done in just a few minutes with some basic logic and javascript!
PREFACE
This is a speedcode tutorial, and I'll assume you have some working knowledge of:
- HTML, CSS, JS
- React
- Good concept of CSS or SASS
- Not necessary, but I'll be using Styled-components ( CSS in JS library )
Resources
Speedcode tutorial ⤵️
Conclusion
Thats it for "How to create a dynamic scrollToTop
button in React! No library necessary! EVER" I hope you enjoyed the video, and hope you never have to use another scroll button library again! Once you get the hang of the code, you'll be able to add this to your website in just a couple minutes, no doubt about it! #happycoding!
Top comments (1)
Sweet, thanks for that input! I've been looking into browser performance best practices but I'm still trying to get better at the basics of react! I'll look into this though 💯