Ind.ie is now Small Technology Foundation.
blocker-activation-test-rule.md 975 Bytes
Newer Older
1
# Better activation test rule.
2

3 4 5 6
## Important!

**Do not edit or remove!** This rule is essential for the proper functioning of the iOS app.

7
This rule blocks the `test.js` script. The Better iOS app loads the `index.html` file which tries to load this script. If the blocker is inactive, the script will load and the browser will be redirected to a URL that signals that the blocker is inactive. If blocked, execution falls through to some inline JavaScript that forwards the browser to a URL that signals that the blocker is active.
8

9 10
Even though this rule is hardcoded into the blockerList.json that’s in the Blocker content blocker extension, that’s only used until the actual data is downloaded via Git. After that, the blockerList.json file from the data-for-apps repository is used. This is the file that adds the rule to that (main) blocker list file.

11 12
```mson
- trigger:
13
	- url-filter: localhost:8000/test.js
14
	- load-type: first-party
15 16
- action:
	- type: block
17
```