Skip to content

Instantly share code, notes, and snippets.

@alemonmk
Last active December 24, 2022 09:24
Show Gist options
  • Save alemonmk/e28bcf69c34a66326cd7aac29d1afbe5 to your computer and use it in GitHub Desktop.
Save alemonmk/e28bcf69c34a66326cd7aac29d1afbe5 to your computer and use it in GitHub Desktop.
My twitter page clean up cosmetic filters
! Remove side columns
twitter.com#?#nav > a[href="/explore"]
twitter.com#?#div[aria-label="Timeline: Trending now"]:upward(3)
twitter.com#?#aside[aria-label="Who to follow"]:upward(1)
twitter.com#?#aside[aria-label="Relevant people"]:upward(1)
! Remove heading for following insertions
twitter.com#?#:not(:matches-path(/topic|list|follow|explore/)) div:has(> div > div > div > h2[role="heading"] > div > span)
twitter.com#?#:matches-path(/status/) div:has(h2:has-text(Related Tweets)) ~ div
! Remove "Topics to follow" insertions
twitter.com#?#:not(:matches-path(topic)) a[href="/i/topics/picker/home"]:upward(2)
twitter.com#?#:not(:matches-path(topic)) div[aria-label="Timeline: Carousel"]:upward(3)
! Removes "Who to follow" insertions
twitter.com#?#div:has(> div > a[href^="/i/connect_people"])
twitter.com#?#:not(:matches-path(/follow|status\/\d{19}\/(retweets|likes)|i\/timeline/)) div[role="button"][data-testid="UserCell"]:has(div[aria-label^="Follow @"]):upward(2)
! Removes "Discover new lists" insertions
twitter.com#?#div:has(> div > a[href^="/i/lists/suggest"])
twitter.com#?#:not(:matches-path(list)) a > div[data-testid="listCell"]:has(div[role="button"]):upward(3)
! Removes "Based on your ..." tweets
twitter.com##a:has(> span[aria-label^="Recommended Topic:"]):upward(16)
! Removes login nags
twitter.com#?##layers > div[class*=" "]:first-of-type:has(a[href="/i/flow/signup"])
! Removes the cookie sticky on bottom
twitter.com###layers > div > div:nth-of-type(2):last-of-type
! Remove notification from verified
twitter.com#?#div > a[role="tab"] > div > div > span:has-text(Verified):upward(4)
! Remove views counter and links to analytics
twitter.com##a[href$="/analytics"][role="menuitem"]
twitter.com##article div:has(> a[href$="/analytics"][role="link"]:has(svg))
twitter.com##:matches-path(/status/) div:has(> div > a[href$="/analytics"][role="link"]:has-text(Views))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment