Skip to content

Commit

Permalink
Use const instead of var for scrollHeight
Browse files Browse the repository at this point in the history
  • Loading branch information
martinkyjac committed Nov 26, 2024
1 parent a77542b commit e98af3f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/Playwright/pageObjects/BasePage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ export class BasePage {
let totalHeight = 0;
const distance = 200;
const timer = setInterval(() => {
var scrollHeight = document.body.scrollHeight;
const scrollHeight = document.body.scrollHeight;
window.scrollBy(0, distance);
totalHeight += distance;
if (totalHeight >= scrollHeight - window.innerHeight) {
Expand Down

0 comments on commit e98af3f

Please sign in to comment.