Skip to content

Instantly share code, notes, and snippets.

@goranmoomin
Created February 23, 2019 09:30
Show Gist options
  • Select an option

  • Save goranmoomin/4511719926d854ab98233b664e670ce3 to your computer and use it in GitHub Desktop.

Select an option

Save goranmoomin/4511719926d854ab98233b664e670ce3 to your computer and use it in GitHub Desktop.
Get all CSS class names
Array.from(document.querySelectorAll("*")).map(el => el.className).filter(x => x).reduce((a, b) => a + " " + b)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment