Skip to content

Instantly share code, notes, and snippets.

@molily
Created December 2, 2015 08:51
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 molily/5eace2f0792c78a9676c to your computer and use it in GitHub Desktop.
Save molily/5eace2f0792c78a9676c to your computer and use it in GitHub Desktop.
JavaScript flamewars
var treeWalker = document.createTreeWalker(document.body, NodeFilter.SHOW_TEXT);
while (treeWalker.nextNode()) {
var node = treeWalker.currentNode;
node.nodeValue = node.nodeValue.replace(/(F|f)ramework/g, '$1lamewar');
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment