您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
yapi to ts
当前为
- // ==UserScript==
- // @name yapiTots
- // @namespace yapiTots
- // @version 0.0.2
- // @description yapi to ts
- // @license MIT
- // @author hjl
- // @match http://*/*
- // @icon https://img2.baidu.com/it/u=3318407772,3634490264&fm=253&fmt=auto?w=1200&h=767
- // @grant none
- // ==/UserScript==
- window.whiteList = ['http://192.168.140.245:3000']
- if(!window.whiteList.includes(window.location.origin)){
- return
- }
- const dayJsUrl = 'https://unpkg.com/dayjs@1.11.7/dayjs.min.js'
- const vueUrl ='https://xyfali.postar.cn/risk-message/vue.js'
- const axiosUrl = 'https://xyfali.postar.cn/risk-message/axios.js'
- const elementCss='https://xyfali.postar.cn/risk-message/element-ui.css'
- const elementJs ='https://xyfali.postar.cn/risk-message/element-ui.js'
- document.querySelector('head').appendChild(createLink(elementCss))
- document.querySelector('head').appendChild(createScript(axiosUrl));
- document.querySelector('head').appendChild(createScript(elementJs));
- document.querySelector('head').appendChild(createScript(dayJsUrl));
- document.querySelector('head').appendChild(createScript(vueUrl));
- function createScript (url,onLoad){
- var script = document.createElement('script');
- script.src = url;
- if(onLoad){
- script.onload=onLoad
- }
- return script
- }
- function createLink (url,onLoad){
- var link = document.createElement('link');
- link.href = url;
- link.setAttribute('rel','stylesheet');
- link.setAttribute('type','text/css');
- if(onLoad){
- link.onload=onLoad
- }
- return link
- }
- const app = document.createElement('div');
- app.id='app'
- document.body.appendChild(app);
- (function() {
- 'use strict';
- window.addEventListener('load', function(e) {
- document.body.appendChild(createScript(`https://xyfali.postar.cn/risk-message/createTs.js?time=${new Date().getTime()}`))
- }, false);
- })();