ScrollIntoView in Chrome
Make sure all your JavaScript code is run after your page completes loading:
document.addEventListener('DOMContentLoaded', function() {
// your code here
}, false);
Or if you're using jQuery:
$(document).ready(function(){
// your code
});
This will make sure that your code runs the way you intend.