Last active
December 25, 2017 04:50
-
-
Save jschaf/212c79f3b378b4d13f055462f487783d to your computer and use it in GitHub Desktop.
TamperMonkey script to prevent Chrome from auto-adding search engines.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name RemoveOpenSearch | |
// @namespace http://tampermonkey.net/ | |
// @version 0.1 | |
// @description Prevent Chrome from automatically adding search engines. | |
// @author Joe Schafer | |
// @match http://*/* | |
// @grant none | |
// ==/UserScript== | |
(function() { | |
'use strict'; | |
const elOpenSearch = document.querySelector('[type="application/opensearchdescription+xml"]'); | |
if (elOpenSearch) elOpenSearch.remove(); | |
})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Does not seem to be working. In order to account for http and https connections to websites I replaced the http:/// with :///*