Skip to content

Automate browser based workflows with AI

fix scrolling failure on some websites (#369)

LawyZhengeab07939f501
diff --git a/skyvern/webeye/scraper/domUtils.js b/skyvern/webeye/scraper/domUtils.js
index 81437439a..158e073b3 100644
--- a/skyvern/webeye/scraper/domUtils.js
+++ b/skyvern/webeye/scraper/domUtils.js
@@ -1184,7 +1184,7 @@ function removeBoundingBoxes() {
function scrollToTop(draw_boxes) {
removeBoundingBoxes();
- window.scrollTo({ left: 0, top: 0, behavior: "instant" });
+ window.scroll({ left: 0, top: 0, behavior: "instant" });
if (draw_boxes) {
var elementsAndResultArray = buildTreeFromBody();
drawBoundingBoxes(elementsAndResultArray[0]);