Portfolio/pages/autoScroll.js
Nye Evans fd2250aa70 minor edits after review from friend
-minor wording changes
-added an autoscroll to help confused users
-added page anchors
-minor css changes for mobile
2021-02-22 22:16:27 +00:00

4 lines
No EOL
206 B
JavaScript

setTimeout(() => {
if (window.scrollY < 20)
window.scrollBy({top: window.innerHeight, left: 0, behavior: 'smooth'})
}, 2000); // we scroll the screen down a bit so the user realises theres more