Made the script start loading before the site is loaded

This commit is contained in:
An0 2020-09-05 13:46:38 +00:00
parent d21b981514
commit 1f111c745d

View file

@ -31,6 +31,7 @@
// @match https://qmining.frylabs.net/* // @match https://qmining.frylabs.net/*
// @match http://qmining.frylabs.net/* // @match http://qmining.frylabs.net/*
// @noframes // @noframes
// @run-at document-start
// @grant GM_getResourceText // @grant GM_getResourceText
// @grant GM_info // @grant GM_info
// @grant GM_getValue // @grant GM_getValue
@ -762,7 +763,12 @@
console.time('main') console.time('main')
timerStarted = true timerStarted = true
Init() if(document.readyState === 'loading') {
document.addEventListener('DOMContentLoaded', Init)
}
else {
Init()
}
} }
function AfterLoad () { function AfterLoad () {