A fast, pure-JavaScript content-blocking library made by Cliqz.
This library is the building block technology used to power Cliqz and Ghostery's Adblocking. Being a pure JavaScript library, it can be used for various purposes such as:
- Building a content-blocking extension (see this example for a minimal content-blocking webextension)
- Building tooling around popular block-lists such as EasyList
- Converting between various formats of filters (EasyList, Safari Block Lists, etc.)
- Detecting duplicates in lists
- Detecting dead domains
- etc.
The library provides the low-level implementation to fetch, parse and match filters; which makes it possible to manipulate the lists at a high level.
Install dependencies:
$ npm install
Build:
$ npm run build
$ npm run bundle
$ npm run bundle
Test:
$ npm run test
You can use the following bundle: adblocker.umd.js
.
To publish a new version:
- Update
version
in package.json - Update CHANGELOG.md
- New commit on local
master
branch (e.g.:Release v0.1.x
) - Add new tag
git tag -f -a vX.Y.Z -m "vX.Y.Z"
- Push release commit + tag
git push upstream master --tags
- Travis takes care of the rest!