Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有一个带有单个元素的网页:一个 3000x3000 的画布,我想将浏览器滚动居中在一个点(具有可变坐标)。我是 html 和 javascript 的初学者,我该怎么做?
滚动窗口:window.scrollTo(x, y)