Skip to content

Instantly share code, notes, and snippets.

@seleniumgists
Created June 17, 2019 14:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save seleniumgists/5784f33ee9c06dcc279da34e33e4e9c8 to your computer and use it in GitHub Desktop.
Save seleniumgists/5784f33ee9c06dcc279da34e33e4e9c8 to your computer and use it in GitHub Desktop.
generated automatically from #selenium on seleniumhq slack
WebElement element = driver.findElement(By.id("id_of_element"));
((JavascriptExecutor) driver).executeScript("arguments[0].scrollIntoView(true);", element);
Thread.sleep(500);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment