Answers for "scrollto top of elemnt"

0

Scroll To Top

const goToTop = () => window.scrollTo(0, 0);

goToTop();
Posted by: Guest on January-07-2022
1

html scroll div to top

var myDiv = document.getElementById('containerDiv');
myDiv.innerHTML = variableLongText;
myDiv.scrollTop = 0;
Posted by: Guest on June-07-2020

Browse Popular Code Answers by Language