scrollTo() function does nothing
问题 I wanted to scroll to the bottom of the page using vanilla JS, but I encountered a problem. The code below is supposed to scroll to the bottom of the page: window.scrollTo(0,document.body.scrollHeight); Whereas all it does is logs "undefined" in the console. Inputting document.body.scrollHeight returns an integer 736. Other than that, it doesn't matter what I input into the function's parameters, nothing happens. What more, it only happens on one website. What may matter (not sure) is that