链接从新标签页打开
As of
// ==UserScript==
// @name tophub&greasyfork新标签页打开
// @namespace mine.com
// @description 链接从新标签页打开
// @match *://tophub.today/*
// @match *://greatest.deepsurf.us/zh-CN/scripts*
// @version 1.0.2
// ==/UserScript==
(function() {
document.querySelectorAll('a').forEach(item => {
//不给空href和greasyfork的page页加_blank
if(!/javascript/.test(item.href) && !/page/.test(item.href)) {
item.setAttribute('target','_blank');
}
});
})();