MCPcopy Index your code
hub / github.com/codeceptjs/CodeceptJS / scrollPageToBottom

Method scrollPageToBottom

lib/helper/WebDriver.js:2888–2896  ·  view source on GitHub ↗

* {{> scrollPageToBottom }}

()

Source from the content-addressed store, hash-verified

2886 * {{> scrollPageToBottom }}
2887 */
2888 scrollPageToBottom() {
2889 const client = this.browser
2890
2891 return client.execute(function () {
2892 const body = document.body
2893 const html = document.documentElement
2894 window.scrollTo(0, Math.max(body.scrollHeight, body.offsetHeight, html.clientHeight, html.scrollHeight, html.offsetHeight))
2895 })
2896 }
2897
2898 /**
2899 * {{> grabPageScrollPosition }}

Callers

nothing calls this directly

Calls 1

scrollToMethod · 0.45

Tested by

no test coverage detected