How to enable smooth scroll on react #185
Answered
by
montasim
AbidHasanPiash
asked this question in
Q&A
-
react |
Beta Was this translation helpful? Give feedback.
Answered by
montasim
Oct 24, 2022
Replies: 1 comment
-
npm i -S react-scroll import { Link, animateScroll as scroll } from "react-scroll"; scrollToTop = () => { |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
AbidHasanPiash
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
npm i -S react-scroll
import { Link, animateScroll as scroll } from "react-scroll";
scrollToTop = () => {
scroll.scrollToTop();
};