xxxxxxxxxx
// easiest way to track on scroll position
if ('scrollRestoration' in history) {
// Back off, browser, I got this...
history.scrollRestoration = 'manual';
}
if ('scrollRestoration' in history) {
// Go on browser, you got this...
history.scrollRestoration = 'auto';
}