This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name test code | |
// @version 1.0 | |
// @match *://*/* | |
// @run-at document-start | |
// ==/UserScript== | |
const selector = '*'; | |
function yourFunction(target) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name preLoadNextPage | |
// @author autoxbc | |
// @version 1.0 | |
// @match *://movie.douban.com/* | |
// @run-at document-start | |
// @require https://cdnjs.cloudflare.com/ajax/libs/URI.js/1.19.1/URI.js | |
// @grant GM_addStyle | |
// ==/UserScript== |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Scheduler { | |
add(promiseCreator) { | |
// 需要实现 | |
const [ runnings , pendings , tick ] = [ | |
['runnings', { size: 0 } ], | |
['pendings', [] ], | |
['tick', () => { | |
if( pendings.length === 0 ) | |
return; | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name keepFocused | |
// @version 0.1 | |
// @match *://*/* | |
// @run-at document-start | |
// ==/UserScript== | |
const blackList = /v2ex|jandan/ig ; | |
const keepFocused = target => { |