Skip to content

Instantly share code, notes, and snippets.

@baptx
Created October 12, 2014 13:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save baptx/3555c1cda4717f362dad to your computer and use it in GitHub Desktop.
Save baptx/3555c1cda4717f362dad to your computer and use it in GitHub Desktop.
Twitter timeline update
var target_tweet = document.getElementsByClassName("stream-container")[0];
var observer = new MutationObserver(function(mutations) {
for (var i = 0; mutations[i]; i++)
document.getElementsByClassName("new-tweets-bar")[0].click();
});
var config = { attributes: true, childList: true, characterData: true }
observer.observe(target_tweet, config);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment