迁移部分内容
Some checks failed
test / Run tests (push) Failing after 55s
build / Build (push) Failing after 1m18s
Some checks failed
test / Run tests (push) Failing after 55s
build / Build (push) Failing after 1m18s
This commit is contained in:
17
example/gm_get_resource.js
Normal file
17
example/gm_get_resource.js
Normal file
@ -0,0 +1,17 @@
|
||||
// ==UserScript==
|
||||
// @name gm get resource
|
||||
// @namespace https://bbs.tampermonkey.net.cn/
|
||||
// @version 0.1.0
|
||||
// @description 通过@resource引用资源,这个资源会被管理器进行缓存,不可修改
|
||||
// @author You
|
||||
// @match https://bbs.tampermonkey.net.cn/
|
||||
// @resource bbs https://bbs.tampermonkey.net.cn/
|
||||
// @grant GM_getResourceURL
|
||||
// @grant GM_getResourceText
|
||||
// ==/UserScript==
|
||||
|
||||
|
||||
console.log(GM_getResourceURL("bbs"));
|
||||
console.log(GM_getResourceURL("bbs", false));
|
||||
console.log(GM_getResourceURL("bbs", true));
|
||||
console.log(GM_getResourceText("bbs"));
|
Reference in New Issue
Block a user