Comment on How to block posts about Elon Musk (or other custom string) on computer

<- View Parent
madsen@lemmy.world ⁨11⁩ ⁨months⁩ ago

You can use the regex: /\\bx\\b/i

It’ll catch ‘x’ surrounded by word boundaries (stuff like spaces, dashes/hyphens, commas, etc.) but not ‘x’ with other letters on either side, so it won’t match e.g. “sax” or “boxer”, but it’ll match “x.com” and “Elon’s X” and stuff. It’s probably not perfect though, so use with caution.

source
Sort:hotnewtop