Try this.
Type this code into your browser console on the homepage of Facebook (your Facebook feed):
setInterval(function(){console.log('blah')}, 100)
Then navigate to the "Messages" or "Events" section of the website. Notice that the whole page is not reloaded and the new html content is inserted dynamically with javascript. However, somehow Facebook cancels the setInterval
. This also happens with setTimeout
.
How is this happening?