您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
一键跳转到github的dev编辑器页面!
当前为
// ==UserScript== // @name 一键跳转到github的dev编辑器页面 // @namespace https://github.com/xxxily // @homepage https://github.com/xxxily // @version 0.0.1 // @description 一键跳转到github的dev编辑器页面! // @author xxxily // @match https://github.com/* // @run-at document-end // @license MIT // ==/UserScript== if(!document.getElementById('goToDev')){ const devBtn = document.createElement("a") devBtn.innerText = "Go to Dev" devBtn.id = "goToDev" devBtn.target = "_blank" devBtn.href = window.location.href.replace("github.com", "github.dev") const btns = document.querySelectorAll("a.btn") btns.forEach(btn => { if(btn.innerText === "Go to file"){ devBtn.className = btn.className btn.parentNode.insertBefore(devBtn, btn) } }) }