怎么在Edge首页执行脚本啊...
-
Edge最近学坏了,在首页加广告了,所以我想脚本去除
用web api获取了首页的地址为https://ntp.msn.cn/edge/ntp
我写的脚本是这样// ==UserScript== // @name New Userscript // @namespace http://tampermonkey.net/ // @version 0.1 // @description try to take over the world! // @author You // @match https://www.tampermonkey.net/index.php?version=4.9&ext=iikm&updated=true // @grant none // @match https://ntp.msn.cn/edge/ntp // ==/UserScript== (function() { 'use strict'; document.getElementById("belowTheFold").style.visibility = "hidden"; document.getElementById("c_chl").style.visibility = "hidden"; document.getElementById("museumCard_titleText").style.visibility = "hidden"; document.getElementsByClassName("legend_taglineWrapper-1")[0].style.visibility = "hidden"; })();
但是在首页不会自动加载脚本...
PS:逐句执行之后可以去广告,效果如下