1
0
mirror of https://github.com/gorhill/uBlock.git synced 2024-07-08 12:57:57 +02:00
uBlock/assets/resources
Raymond Hill 6831967f5f
Add new scriptlet to defuse calls to requestAnimationFrame
Scriptlet name: `raf-if.js`

Usage: `example.com##+js(raf-if, !/(\d+){4}/)`

Argument: one single argument, which is the "needle" to
find in the stringified argument passed to
requestAnimationFrame.

requestAnimationFrame will be defused when:

- The needle is not prefixed with `!` and the needle
  does not match the stringified argument; OR
- The needle is prefixed with `!` and the needle
  matches the stringified argument.

The `raf-if.js` scriptlet will log calls to
requestAnimationFrame to the console when no parameter
is provided, i.e.:

    example.com##+js(raf-if)

Otherwise no logging occurs.
2019-08-21 10:13:23 -04:00
..
scriptlets.js Add new scriptlet to defuse calls to requestAnimationFrame 2019-08-21 10:13:23 -04:00