{"action":"created","comment":{"url":"https://api.github.com/repos/rollbar/rollbar.js/pulls/comments/59483362","id":59483362,"diff_hunk":"@@ -0,0 +1,77 @@\n+# Dealing with Browser-Extension Exceptions\n+\n+For most websites, the path for dealing with browser extension originating exceptions is simply to:\n+\n+1.  Identify the presence of problematic browser extensions\n+2.  Disable Rollbar.js's reporting\n+\n+## Dealing with adblockers\n+\n+The most common type of extension that can be problematic is adblockers.  These extensions can disable loading\n+certain external scripts or remove elements from a page based on a simple set of heuristics. \n+\n+You can see a [full example](https://github.com/rollbar/rollbar.js/tree/master/examples/extension-exceptions/) \n+for details, but the approach can best summarized as below:\n+\n+Load Rollbar.js as normal.\n+\n+```html\n+<script src=\"/assets/js/rollbar.js\"></script>\n+\n+<script>\n+  var _rollbarConfig = {\n+    accessToken: 'POST_CLIENT_ITEM_ACCESS_TOKEN',\n+    captureUncaught: true,\n+    payload: {\n+      environment: 'development',\n+    }\n+  };\n+</script>\n+```\n+\n+Add an html element with \"bait\" class names to be removed by adblockers.\n+\n+```html\n+<!-- bait for adblocker like addons.  If they remove this div, we should disable error reporting -->\n+<div id=\"blocker-bait\" style=\"height: 1px; width: 1px; position: absolute; left: -999em; top: -999em\"\n+     class=\"ads ad adsbox doubleclick ad-placement carbon-ads\"></div>","path":"docs/extension-exceptions.md","position":37,"original_position":37,"commit_id":"bd0611d2aaee48fe8f82b4584dc487906b695712","original_commit_id":"bd0611d2aaee48fe8f82b4584dc487906b695712","user":{"login":"brianr","id":12275,"avatar_url":"https://avatars.githubusercontent.com/u/12275?v=3","gravatar_id":"","url":"https://api.github.com/users/brianr","html_url":"https://github.com/brianr","followers_url":"https://api.github.com/users/brianr/followers","following_url":"https://api.github.com/users/brianr/following{/other_user}","gists_url":"https://api.github.com/users/brianr/gists{/gist_id}","starred_url":"https://api.github.com/users/brianr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/brianr/subscriptions","organizations_url":"https://api.github.com/users/brianr/orgs","repos_url":"https://api.github.com/users/brianr/repos","events_url":"https://api.github.com/users/brianr/events{/privacy}","received_events_url":"https://api.github.com/users/brianr/received_events","type":"User","site_admin":false},"body":"Clever. What adblockers have you tested this with?","created_at":"2016-04-13T02:02:04Z","updated_at":"2016-04-13T02:02:04Z","html_url":"https://github.com/rollbar/rollbar.js/pull/190#discussion_r59483362","pull_request_url":"https://api.github.com/repos/rollbar/rollbar.js/pulls/190","_links":{"self":{"href":"https://api.github.com/repos/rollbar/rollbar.js/pulls/comments/59483362"},"html":{"href":"https://github.com/rollbar/rollbar.js/pull/190#discussion_r59483362"},"pull_request":{"href":"https://api.github.com/repos/rollbar/rollbar.js/pulls/190"}}},"pull_request":{"url":"https://api.github.com/repos/rollbar/rollbar.js/pulls/190","id":66251612,"html_url":"https://github.com/rollbar/rollbar.js/pull/190","diff_url":"https://github.com/rollbar/rollbar.js/pull/190.diff","patch_url":"https://github.com/rollbar/rollbar.js/pull/190.patch","issue_url":"https://api.github.com/repos/rollbar/rollbar.js/issues/190","number":190,"state":"open","locked":false,"title":"Adding example and documentation related to adblockers","user":{"login":"corps","id":593850,"avatar_url":"https://avatars.githubusercontent.com/u/593850?v=3","gravatar_id":"","url":"https://api.github.com/users/corps","html_url":"https://github.com/corps","followers_url":"https://api.github.com/users/corps/followers","following_url":"https://api.github.com/users/corps/following{/other_user}","gists_url":"https://api.github.com/users/corps/gists{/gist_id}","starred_url":"https://api.github.com/users/corps/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/corps/subscriptions","organizations_url":"https://api.github.com/users/corps/orgs","repos_url":"https://api.github.com/users/corps/repos","events_url":"https://api.github.com/users/corps/events{/privacy}","received_events_url":"https://api.github.com/users/corps/received_events","type":"User","site_admin":false},"body":"@coryvirok @brianr \r\n\r\nThis addresses [Issue 182](https://github.com/rollbar/rollbar.js/issues/182) by adding an example an a related doc file.  Let me know of any improvements you'd like to see!","created_at":"2016-04-13T00:57:24Z","updated_at":"2016-04-13T02:02:04Z","closed_at":null,"merged_at":null,"merge_commit_sha":"1ca0ffbf74c9c32c7540999ba8a5b54012f1348f","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/rollbar/rollbar.js/pulls/190/commits","review_comments_url":"https://api.github.com/repos/rollbar/rollbar.js/pulls/190/comments","review_comment_url":"https://api.github.com/repos/rollbar/rollbar.js/pulls/comments{/number}","comments_url":"https://api.github.com/repos/rollbar/rollbar.js/issues/190/comments","statuses_url":"https://api.github.com/repos/rollbar/rollbar.js/statuses/bd0611d2aaee48fe8f82b4584dc487906b695712","head":{"label":"corps:dealing-with-adblockers","ref":"dealing-with-adblockers","sha":"bd0611d2aaee48fe8f82b4584dc487906b695712","user":{"login":"corps","id":593850,"avatar_url":"https://avatars.githubusercontent.com/u/593850?v=3","gravatar_id":"","url":"https://api.github.com/users/corps","html_url":"https://github.com/corps","followers_url":"https://api.github.com/users/corps/followers","following_url":"https://api.github.com/users/corps/following{/other_user}","gists_url":"https://api.github.com/users/corps/gists{/gist_id}","starred_url":"https://api.github.com/users/corps/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/corps/subscriptions","organizations_url":"https://api.github.com/users/corps/orgs","repos_url":"https://api.github.com/users/corps/repos","events_url":"https://api.github.com/users/corps/events{/privacy}","received_events_url":"https://api.github.com/users/corps/received_events","type":"User","site_admin":false},"repo":{"id":56104676,"name":"rollbar.js","full_name":"corps/rollbar.js","owner":{"login":"corps","id":593850,"avatar_url":"https://avatars.githubusercontent.com/u/593850?v=3","gravatar_id":"","url":"https://api.github.com/users/corps","html_url":"https://github.com/corps","followers_url":"https://api.github.com/users/corps/followers","following_url":"https://api.github.com/users/corps/following{/other_user}","gists_url":"https://api.github.com/users/corps/gists{/gist_id}","starred_url":"https://api.github.com/users/corps/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/corps/subscriptions","organizations_url":"https://api.github.com/users/corps/orgs","repos_url":"https://api.github.com/users/corps/repos","events_url":"https://api.github.com/users/corps/events{/privacy}","received_events_url":"https://api.github.com/users/corps/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/corps/rollbar.js","description":"Error tracking and logging from JS to Rollbar","fork":true,"url":"https://api.github.com/repos/corps/rollbar.js","forks_url":"https://api.github.com/repos/corps/rollbar.js/forks","keys_url":"https://api.github.com/repos/corps/rollbar.js/keys{/key_id}","collaborators_url":"https://api.github.com/repos/corps/rollbar.js/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/corps/rollbar.js/teams","hooks_url":"https://api.github.com/repos/corps/rollbar.js/hooks","issue_events_url":"https://api.github.com/repos/corps/rollbar.js/issues/events{/number}","events_url":"https://api.github.com/repos/corps/rollbar.js/events","assignees_url":"https://api.github.com/repos/corps/rollbar.js/assignees{/user}","branches_url":"https://api.github.com/repos/corps/rollbar.js/branches{/branch}","tags_url":"https://api.github.com/repos/corps/rollbar.js/tags","blobs_url":"https://api.github.com/repos/corps/rollbar.js/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/corps/rollbar.js/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/corps/rollbar.js/git/refs{/sha}","trees_url":"https://api.github.com/repos/corps/rollbar.js/git/trees{/sha}","statuses_url":"https://api.github.com/repos/corps/rollbar.js/statuses/{sha}","languages_url":"https://api.github.com/repos/corps/rollbar.js/languages","stargazers_url":"https://api.github.com/repos/corps/rollbar.js/stargazers","contributors_url":"https://api.github.com/repos/corps/rollbar.js/contributors","subscribers_url":"https://api.github.com/repos/corps/rollbar.js/subscribers","subscription_url":"https://api.github.com/repos/corps/rollbar.js/subscription","commits_url":"https://api.github.com/repos/corps/rollbar.js/commits{/sha}","git_commits_url":"https://api.github.com/repos/corps/rollbar.js/git/commits{/sha}","comments_url":"https://api.github.com/repos/corps/rollbar.js/comments{/number}","issue_comment_url":"https://api.github.com/repos/corps/rollbar.js/issues/comments{/number}","contents_url":"https://api.github.com/repos/corps/rollbar.js/contents/{+path}","compare_url":"https://api.github.com/repos/corps/rollbar.js/compare/{base}...{head}","merges_url":"https://api.github.com/repos/corps/rollbar.js/merges","archive_url":"https://api.github.com/repos/corps/rollbar.js/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/corps/rollbar.js/downloads","issues_url":"https://api.github.com/repos/corps/rollbar.js/issues{/number}","pulls_url":"https://api.github.com/repos/corps/rollbar.js/pulls{/number}","milestones_url":"https://api.github.com/repos/corps/rollbar.js/milestones{/number}","notifications_url":"https://api.github.com/repos/corps/rollbar.js/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/corps/rollbar.js/labels{/name}","releases_url":"https://api.github.com/repos/corps/rollbar.js/releases{/id}","deployments_url":"https://api.github.com/repos/corps/rollbar.js/deployments","created_at":"2016-04-12T23:20:52Z","updated_at":"2016-04-12T23:20:56Z","pushed_at":"2016-04-13T00:56:15Z","git_url":"git://github.com/corps/rollbar.js.git","ssh_url":"git@github.com:corps/rollbar.js.git","clone_url":"https://github.com/corps/rollbar.js.git","svn_url":"https://github.com/corps/rollbar.js","homepage":"https://rollbar.com/docs/notifier/rollbar.js/","size":4099,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"rollbar:master","ref":"master","sha":"a072cb78a9056ebded63879e6eec473d6ff1752d","user":{"login":"rollbar","id":3219584,"avatar_url":"https://avatars.githubusercontent.com/u/3219584?v=3","gravatar_id":"","url":"https://api.github.com/users/rollbar","html_url":"https://github.com/rollbar","followers_url":"https://api.github.com/users/rollbar/followers","following_url":"https://api.github.com/users/rollbar/following{/other_user}","gists_url":"https://api.github.com/users/rollbar/gists{/gist_id}","starred_url":"https://api.github.com/users/rollbar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rollbar/subscriptions","organizations_url":"https://api.github.com/users/rollbar/orgs","repos_url":"https://api.github.com/users/rollbar/repos","events_url":"https://api.github.com/users/rollbar/events{/privacy}","received_events_url":"https://api.github.com/users/rollbar/received_events","type":"Organization","site_admin":false},"repo":{"id":7136784,"name":"rollbar.js","full_name":"rollbar/rollbar.js","owner":{"login":"rollbar","id":3219584,"avatar_url":"https://avatars.githubusercontent.com/u/3219584?v=3","gravatar_id":"","url":"https://api.github.com/users/rollbar","html_url":"https://github.com/rollbar","followers_url":"https://api.github.com/users/rollbar/followers","following_url":"https://api.github.com/users/rollbar/following{/other_user}","gists_url":"https://api.github.com/users/rollbar/gists{/gist_id}","starred_url":"https://api.github.com/users/rollbar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rollbar/subscriptions","organizations_url":"https://api.github.com/users/rollbar/orgs","repos_url":"https://api.github.com/users/rollbar/repos","events_url":"https://api.github.com/users/rollbar/events{/privacy}","received_events_url":"https://api.github.com/users/rollbar/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/rollbar/rollbar.js","description":"Error tracking and logging from JS to Rollbar","fork":false,"url":"https://api.github.com/repos/rollbar/rollbar.js","forks_url":"https://api.github.com/repos/rollbar/rollbar.js/forks","keys_url":"https://api.github.com/repos/rollbar/rollbar.js/keys{/key_id}","collaborators_url":"https://api.github.com/repos/rollbar/rollbar.js/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/rollbar/rollbar.js/teams","hooks_url":"https://api.github.com/repos/rollbar/rollbar.js/hooks","issue_events_url":"https://api.github.com/repos/rollbar/rollbar.js/issues/events{/number}","events_url":"https://api.github.com/repos/rollbar/rollbar.js/events","assignees_url":"https://api.github.com/repos/rollbar/rollbar.js/assignees{/user}","branches_url":"https://api.github.com/repos/rollbar/rollbar.js/branches{/branch}","tags_url":"https://api.github.com/repos/rollbar/rollbar.js/tags","blobs_url":"https://api.github.com/repos/rollbar/rollbar.js/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/rollbar/rollbar.js/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/rollbar/rollbar.js/git/refs{/sha}","trees_url":"https://api.github.com/repos/rollbar/rollbar.js/git/trees{/sha}","statuses_url":"https://api.github.com/repos/rollbar/rollbar.js/statuses/{sha}","languages_url":"https://api.github.com/repos/rollbar/rollbar.js/languages","stargazers_url":"https://api.github.com/repos/rollbar/rollbar.js/stargazers","contributors_url":"https://api.github.com/repos/rollbar/rollbar.js/contributors","subscribers_url":"https://api.github.com/repos/rollbar/rollbar.js/subscribers","subscription_url":"https://api.github.com/repos/rollbar/rollbar.js/subscription","commits_url":"https://api.github.com/repos/rollbar/rollbar.js/commits{/sha}","git_commits_url":"https://api.github.com/repos/rollbar/rollbar.js/git/commits{/sha}","comments_url":"https://api.github.com/repos/rollbar/rollbar.js/comments{/number}","issue_comment_url":"https://api.github.com/repos/rollbar/rollbar.js/issues/comments{/number}","contents_url":"https://api.github.com/repos/rollbar/rollbar.js/contents/{+path}","compare_url":"https://api.github.com/repos/rollbar/rollbar.js/compare/{base}...{head}","merges_url":"https://api.github.com/repos/rollbar/rollbar.js/merges","archive_url":"https://api.github.com/repos/rollbar/rollbar.js/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/rollbar/rollbar.js/downloads","issues_url":"https://api.github.com/repos/rollbar/rollbar.js/issues{/number}","pulls_url":"https://api.github.com/repos/rollbar/rollbar.js/pulls{/number}","milestones_url":"https://api.github.com/repos/rollbar/rollbar.js/milestones{/number}","notifications_url":"https://api.github.com/repos/rollbar/rollbar.js/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/rollbar/rollbar.js/labels{/name}","releases_url":"https://api.github.com/repos/rollbar/rollbar.js/releases{/id}","deployments_url":"https://api.github.com/repos/rollbar/rollbar.js/deployments","created_at":"2012-12-12T20:00:01Z","updated_at":"2016-04-12T20:07:45Z","pushed_at":"2016-04-13T00:57:24Z","git_url":"git://github.com/rollbar/rollbar.js.git","ssh_url":"git@github.com:rollbar/rollbar.js.git","clone_url":"https://github.com/rollbar/rollbar.js.git","svn_url":"https://github.com/rollbar/rollbar.js","homepage":"https://rollbar.com/docs/notifier/rollbar.js/","size":4047,"stargazers_count":74,"watchers_count":74,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":42,"mirror_url":null,"open_issues_count":21,"forks":42,"open_issues":21,"watchers":74,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/rollbar/rollbar.js/pulls/190"},"html":{"href":"https://github.com/rollbar/rollbar.js/pull/190"},"issue":{"href":"https://api.github.com/repos/rollbar/rollbar.js/issues/190"},"comments":{"href":"https://api.github.com/repos/rollbar/rollbar.js/issues/190/comments"},"review_comments":{"href":"https://api.github.com/repos/rollbar/rollbar.js/pulls/190/comments"},"review_comment":{"href":"https://api.github.com/repos/rollbar/rollbar.js/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/rollbar/rollbar.js/pulls/190/commits"},"statuses":{"href":"https://api.github.com/repos/rollbar/rollbar.js/statuses/bd0611d2aaee48fe8f82b4584dc487906b695712"}}}}