Skip to content

Instantly share code, notes, and snippets.

@kentbrew
Last active November 30, 2017 23:44
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kentbrew/e2b94422ef5521db28e9a2bbedb404f0 to your computer and use it in GitHub Desktop.
Save kentbrew/e2b94422ef5521db28e9a2bbedb404f0 to your computer and use it in GitHub Desktop.
Tracker Jacker
const BLOCK_ME = "://www.facebook.com/tr/";
chrome.webRequest.onBeforeRequest.addListener(
function(r) {
return {
cancel: r.url.indexOf(BLOCK_ME) != -1
};
},
{urls: ["<all_urls>"]},
["blocking"]
);
{
"version": "1.0.1",
"name": "Tracker Jacker",
"description": "Quit sending data back to Facebook every time you touch a page with their third-party JavaScript onboard.",
"permissions": [
"webRequest",
"webRequestBlocking",
"*://*/*"
],
"background": {
"scripts": ["background.js" ]
},
"icons": {
"16": "icon_16.png",
"48": "icon_48.png",
"128": "icon_128.png"
},
"content_security_policy": "script-src 'self'; object-src 'self'",
"manifest_version": 2
}
@kentbrew
Copy link
Author

icon_16
icon_48
icon_128

@kentbrew
Copy link
Author

Icons are in the previous comment; stolen from The Noun Project, here:

https://thenounproject.com/term/wasp/902714/

Why the heck GitHub lets you drag an image into a comment but not the gist itself is beyond me.

@kentbrew
Copy link
Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment