Portfolio/scripts/autoScroll.js

4 lines
211 B
JavaScript
Raw Normal View History

setTimeout(() => {
if (window.scrollY < 20)
2021-04-21 23:31:43 +01:00
window.scrollBy({top: window.innerHeight - 70, left: 0, behavior: 'smooth'})
}, 1800); // we scroll the screen down a bit so the user realises theres more