Remove Text Fragment from Google search result URLs
当前为
// ==UserScript==
// @name Remove Text Fragment
// @name:ja Text Fragmentの削除
// @namespace https://greasyfork.org/users/783910
// @version 0.4
// @description Remove Text Fragment from Google search result URLs
// @description:ja Google検索結果のURLからText Fragmentを削除する
// @author ysnr777
// @match https://www.google.com/search?*
// @grant none
// @license MIT
// ==/UserScript==
(function() {
'use strict';
for (const el of document.querySelectorAll("a[href*=':~:']")) {
el.href = el.href.replace(/#:~:[^"]*/, '');
}
})();