1
0
mirror of https://github.com/gorhill/uBlock.git synced 2024-07-05 11:37:01 +02:00

Updated Cosmetic filtering in µBlock: version 0.4.0.0 update (markdown)

Raymond Hill 2014-08-14 16:41:53 -07:00
parent b02a7f2667
commit 2e82a9c4b9

@ -10,7 +10,7 @@ However the inconvenience is that the HTML elements which need to be hidden from
One solution to mitigate this was to introduce a while ago the concept of entity-based cosmetic filters. This new class of cosmetic filters allows µBlock to inject such cosmetic filters without having to wait for the primary DOM to be available, hence the HTML elements which are targeted will be hidden early enough, before the page displays.
So far only the generic filters which purpose is to hide ads on Google search page have benefited from that new class of cosmetic filters. This was a best-case scenario for such cosmetic filters, because ads for the Google search page must be hidden on `google.com`, `google.ca`, `google.com.br`, etc. For example, there exist entity-based filters for `google.*`, which means they will be injected in any of the Google domain. Not being able to use a wildcard as suffix is why Adblock Plus is forced to use generic cosmetic filters for those filters which purpose is to remove ads from Google search web page.
So far only the generic filters which purpose is to hide ads on Google search page have benefited from that new class of cosmetic filters. This was a best-case scenario for such cosmetic filters, because ads for the Google search page must be hidden on `google.com`, `google.ca`, `google.com.br`, etc. For example, there exist entity-based filters for `google.*`, which means they will be injected in any of the Google domain. Not being able to use a wildcard as suffix for hostnames in cosmetic filters is why Adblock Plus is forced to use generic cosmetic filters for those filters which purpose is to remove ads from Google search web page.
Still, entity-based filters are not a solution for the vast majority of generic cosmetic filters (14,000+ generic cosmetic filters just in _EasyList_).