A fetch-like polyfill for userscript managers.(TM,GM,VM)
        此脚本不应直接安装。它是供其他脚本使用的外部库,要使用该库请加入元指令 // @require https://update.cn-greasyfork.org/scripts/372917/639024/gmxhr-fetch.js
      
A fetch-like polyfill for userscript managers.(TM,GM,VM)
Add the following content into your script's metablock.
// @require https://unpkg.com/gmxhr-fetch
// @grant   GM_xmlhttpRequest
// @grant   GM.xmlHttpRequest
Then you can call gmfetch anywhere in the script just like fetch.
gmfetch('https://example.com').then(console.log)