DuckDuckGo - Restore "home" "end"

Restore the conventional usage of the "home" & "end" keys in the search field

Versión del día 14/07/2025. Echa un vistazo a la versión más reciente.

// ==UserScript==
// @name         DuckDuckGo - Restore "home" "end"
// @namespace    https://github.com/Procyon-b
// @version      1.0
// @description  Restore the conventional usage of the "home" & "end" keys in the search field
// @author       Achernar
// @match        https://duckduckgo.com/*
// @match        https://noai.duckduckgo.com/*
// @grant        none
// ==/UserScript==

(function() {

document.addEventListener("keydown", function(ev) {
  if (ev.target.nodeName == 'INPUT' && ev.target.id.startsWith('search') && ['Home', 'End'].includes(ev.key) ) {
    ev.stopPropagation();
    }
  }, true);

})();