Skip welcome & menu and move to editor
Welcome to JS Bin
Load cached copy from
 
<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <title>JS Bin</title>
</head>
<body>
<div id="superHigh"></div>
<div id="indicator"></div>
</body>
</html>
 
#superHigh {
    width: 100%;
    height: 2100px;
    background: teal;
}
#indicator {
    position: fixed;
    top: 10px;
    right: auto;
    bottom: auto;
    left: 10px;
}
}
 
var currentPosition = 0;
var updatePosition = function() {
    currentPosition = window.pageYOffset || document.documentElement.scrollTop;
  
  document.getElementById('indicator').textContent = currentPosition;
};
document.addEventListener('scroll', updatePosition);
Output

You can jump to the latest bin by adding /latest to your URL

Dismiss x
public
Bin info
anonymouspro
0viewers