Skip to content

Instantly share code, notes, and snippets.

@kawanet
Created May 19, 2015 10:06
Show Gist options
  • Save kawanet/111884a339b43b1b599f to your computer and use it in GitHub Desktop.
Save kawanet/111884a339b43b1b599f to your computer and use it in GitHub Desktop.
remove DOM elements without jQuery
// $("#id").remove();
Array.prototype.forEach.call(document.querySelectorAll("#id"), Function.prototype.call.bind(document.body.remove));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment