Show HN: Two uBlock Origin rules to improve your Twitch experience
&gt; Twitch generates random class names, possibly to prevent your blocking some elements, so I tried to find the topmost classes.<p>I don&#x27;t use Twitch, so I&#x27;m not sure what these rules are blocking, but if there&#x27;s any bit of consistent text in the elements these are targeting, you can do something like<p><pre><code>    twitch.tv##div:has-text(Text To Block):xpath(..&#x2F;..)
</code></pre>
There may be ways around this, ie here&#x27;s the lengths Facebook go to write the word &quot;Sponsored&quot;:<p><pre><code>    &lt;a
      aria-label=&quot;label&quot;
      class=&quot;oajrlxb2 g5ia77u1 qu0x051f esr5mh6w e9989ue4 r7d6kgcz rq0escxv nhd2j8a9 nc684nl6 p7hjln8o kvgmc6g5 cxmmr5t8 oygrvhab hcukyx3x jb3vyjys rz4wbd8a qt6c0cv9 a8nywdso i1ao9s8h esuyzwwr f1sip0of lzcic4wl gmql0nx0 gpro0wi8 b1v8xokw&quot;
      href=&quot;&#x2F;ads&#x2F;about&#x2F;?__cft__[0]=AZXrXEHuX_dD86iokjfchbSBrQ_82Tl3Un_9I6DwUiWYhK3t_v9M6fjRm2c2e3Ca45tcXk-oTF0IPtcCqR0T6NLHXlbRXN7QxfDwF_Xydka_MzBz8Y9MNk4b7FPb7qbFiALU6PjCE-RKXIbAwAU1uJXL3QLmPMUXDvIXi97x445-5WceUPJAKY7xekY5wDjA-TQacU37LvU3P5vATZyixPQBikeTOkPq_7EI410wzlGsoZlC1yMhE9L1lFuiwuWMK4VxsXB2zIvFjJqX0JjBHAP9ea1t9QmGKlff9cu1hO6crg&amp;amp;__tn__=,P-R&quot;
      role=&quot;link&quot;
      tabindex=&quot;0&quot;
    &gt;
      &lt;span&gt;
        &lt;span class=&quot;j1lvzwm4 stjgntxs ni8dbmo4 q9uorilb gpro0wi8&quot;&gt;
          &lt;b class=&quot;t5a262vz nc684nl6 ihxqhq3m l94mrbxd aenfhxwr l9j0dhe7 sdhka5h4&quot;&gt;
            &lt;b
              class=&quot;l94mrbxd aenfhxwr myohyog2 b6zbclly l9j0dhe7 sdhka5h4 ww7X6RO&quot;
              style=&quot;display: none&quot;
            &gt;
              -
            &lt;&#x2F;b&gt;
            &lt;b
              class=&quot;l94mrbxd aenfhxwr myohyog2 b6zbclly l9j0dhe7 sdhka5h4 ww7X6RO&quot;
              style=&quot;display: none&quot;
            &gt;
              -
            &lt;&#x2F;b&gt;
            &lt;b
              class=&quot;l94mrbxd aenfhxwr myohyog2 b6zbclly l9j0dhe7 sdhka5h4 ww7X6RO&quot;
              style=&quot;display: none&quot;
            &gt;
              -
            &lt;&#x2F;b&gt;
            &lt;b
              class=&quot;l94mrbxd aenfhxwr myohyog2 b6zbclly l9j0dhe7 sdhka5h4 ww7X6RO&quot;
              style=&quot;display: none&quot;
            &gt;
              -
            &lt;&#x2F;b&gt;
            &lt;b class=&quot;nc684nl6 l94mrbxd l9j0dhe7 sdhka5h4&quot;&gt;S&lt;&#x2F;b&gt;
            &lt;b
              class=&quot;t5a262vz nc684nl6 ihxqhq3m l94mrbxd aenfhxwr l9j0dhe7 sdhka5h4&quot;
            &gt;
              p
            &lt;&#x2F;b&gt;
            &lt;b
              class=&quot;l94mrbxd aenfhxwr myohyog2 b6zbclly l9j0dhe7 sdhka5h4 ww7X6RO&quot;
              style=&quot;display: none&quot;
            &gt;
              -
            &lt;&#x2F;b&gt;
            &lt;b
              class=&quot;l94mrbxd aenfhxwr myohyog2 b6zbclly l9j0dhe7 sdhka5h4 ww7X6RO&quot;
              style=&quot;display: none&quot;
            &gt;
              -
            &lt;&#x2F;b&gt;
            &lt;b
              class=&quot;l94mrbxd aenfhxwr myohyog2 b6zbclly l9j0dhe7 sdhka5h4 ww7X6RO&quot;
              style=&quot;display: none&quot;
            &gt;
              -
            &lt;&#x2F;b&gt;
            &lt;b
              class=&quot;l94mrbxd aenfhxwr myohyog2 b6zbclly l9j0dhe7 sdhka5h4 ww7X6RO&quot;
              style=&quot;display: none&quot;
            &gt;
              -
            &lt;&#x2F;b&gt;
            &lt;b class=&quot;myohyog2 l9j0dhe7 sdhka5h4&quot;&gt;o&lt;&#x2F;b&gt;
            &lt;b class=&quot;b6zbclly l9j0dhe7 sdhka5h4&quot;&gt;n&lt;&#x2F;b&gt;
            &lt;b
              class=&quot;l94mrbxd aenfhxwr myohyog2 b6zbclly l9j0dhe7 sdhka5h4 ww7X6RO&quot;
              style=&quot;display: none&quot;
            &gt;
              -
            &lt;&#x2F;b&gt;
            &lt;b class=&quot;nc684nl6 l94mrbxd l9j0dhe7 sdhka5h4&quot;&gt;s&lt;&#x2F;b&gt;
            &lt;b class=&quot;myohyog2 l9j0dhe7 sdhka5h4&quot;&gt;o&lt;&#x2F;b&gt;
            &lt;b
              class=&quot;l94mrbxd aenfhxwr myohyog2 b6zbclly l9j0dhe7 sdhka5h4 ww7X6RO&quot;
              style=&quot;display: none&quot;
            &gt;
              -
            &lt;&#x2F;b&gt;
            &lt;b
              class=&quot;l94mrbxd aenfhxwr myohyog2 b6zbclly l9j0dhe7 sdhka5h4 ww7X6RO&quot;
              style=&quot;display: none&quot;
            &gt;
              -
            &lt;&#x2F;b&gt;
            &lt;b class=&quot;t5a262vz l94mrbxd myohyog2 l9j0dhe7 sdhka5h4&quot;&gt;r&lt;&#x2F;b&gt;
            &lt;b
              class=&quot;l94mrbxd aenfhxwr myohyog2 b6zbclly l9j0dhe7 sdhka5h4 ww7X6RO&quot;
              style=&quot;display: none&quot;
            &gt;
              -
            &lt;&#x2F;b&gt;
            &lt;b
              class=&quot;l94mrbxd aenfhxwr myohyog2 b6zbclly l9j0dhe7 sdhka5h4 ww7X6RO&quot;
              style=&quot;display: none&quot;
            &gt;
              -
            &lt;&#x2F;b&gt;
            &lt;b
              class=&quot;l94mrbxd aenfhxwr myohyog2 b6zbclly l9j0dhe7 sdhka5h4 ww7X6RO&quot;
              style=&quot;display: none&quot;
            &gt;
              -
            &lt;&#x2F;b&gt;
            &lt;b
              class=&quot;l94mrbxd aenfhxwr myohyog2 b6zbclly l9j0dhe7 sdhka5h4 ww7X6RO&quot;
              style=&quot;display: none&quot;
            &gt;
              -
            &lt;&#x2F;b&gt;
            &lt;b
              class=&quot;l94mrbxd aenfhxwr myohyog2 b6zbclly l9j0dhe7 sdhka5h4 ww7X6RO&quot;
              style=&quot;display: none&quot;
            &gt;
              -
            &lt;&#x2F;b&gt;
            &lt;b class=&quot;l94mrbxd aenfhxwr myohyog2 b6zbclly l9j0dhe7 sdhka5h4&quot;&gt;e&lt;&#x2F;b&gt;
            &lt;b class=&quot;ihxqhq3m myohyog2 l9j0dhe7 sdhka5h4&quot;&gt;d&lt;&#x2F;b&gt;
            &lt;b
              class=&quot;l94mrbxd aenfhxwr myohyog2 b6zbclly l9j0dhe7 sdhka5h4 ww7X6RO&quot;
              style=&quot;display: none&quot;
            &gt;
              -
            &lt;&#x2F;b&gt;
            &lt;b
              class=&quot;l94mrbxd aenfhxwr myohyog2 b6zbclly l9j0dhe7 sdhka5h4 ww7X6RO&quot;
              style=&quot;display: none&quot;
            &gt;
              -
            &lt;&#x2F;b&gt;
            &lt;b
              class=&quot;l94mrbxd aenfhxwr myohyog2 b6zbclly l9j0dhe7 sdhka5h4 ww7X6RO&quot;
              style=&quot;display: none&quot;
            &gt;
              -
            &lt;&#x2F;b&gt;
          &lt;&#x2F;b&gt;
        &lt;&#x2F;span&gt;
      &lt;&#x2F;span&gt;
    &lt;&#x2F;a&gt;</code></pre>