ScrollTO

PHOTO EMBED

Wed Jan 19 2022 14:10:03 GMT+0000 (UTC)

Saved by @ITAG #javascript #remove #duplicate

export const scrollTo = (distance) => {
    window.scrollTo({
        top: distance,
        behavior: 'smooth'
    })
}

export const scrollToTop = () => scrollTo(0)
content_copyCOPY

scrollTo