Skip to content

Instantly share code, notes, and snippets.

@hungsu
Last active March 26, 2020 14:14
Show Gist options
  • Save hungsu/6227136 to your computer and use it in GitHub Desktop.
Save hungsu/6227136 to your computer and use it in GitHub Desktop.
Scroll to top of page, cross browser
document.body.scrollTop = document.documentElement.scrollTop = 0;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment