|
|
|
|
|
by huhtenberg
1247 days ago
|
|
It can't be done with uBlock because Twitter randomized pretty much all DOM element class names. You really need to parse the content, then climb up the tree and trim grand/parent nodes to remove all the junk. Used to be much easier few years ago with descriptive class names, but they changed that. * I'm not the OP, but I made a similar extension. |
|
They've handily left a bunch of data-testid attributes on some of the major elements you need to identify, like the primary column.
Since it's a React app, manually removing stuff from the DOM will either have your changes get blown away the on the next render, or cause issues on the next render. A good trick is to add your own descriptive classes to <body> for the current screen so you can limit the scope of some of the incredibly gnarly CSS selectors you'll need to use to hide things.