I am working on filter rules for uBlock Origin and wanted to test them against a custom, locally saved HTML page. However, I don’t know how to filter elements that aren’t hosted on a public website.
First, I tried enabling “Allow access to file URLs” for the uBlock Origin extension in Microsoft Edge (Manage Extensions > uBlock Origin > Details). I then created a local HTML file and opened it. However, the button to select elements to block was missing.
I also tried manually entering the filter rule using the file path as a domain, (IE: C:/Test/test.html##div and file:///C:/Test/test.html##), but it failed with the error “Invalid filter: Bad domain name”.
How can I test uBlock Origin filters against a custom, locally saved HTML file?