Skip to content

Commit 1a1bd83

Browse files
committed
fix: 修正跳转打开时样式缺失的bug
1 parent ae99fe4 commit 1a1bd83

File tree

2 files changed

+5
-11
lines changed

2 files changed

+5
-11
lines changed

src/config/ui/menu.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ function currentInProjectRepo() {
3838
}
3939

4040
module.exports = {
41-
registerMenu
41+
registerMenu,
42+
show
4243
}
4344

src/init/init.js

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
const {registerMenu} = require("../config/ui/menu");
2-
const {Debugger} = require("../debugger/debugger");
1+
const {registerMenu, show} = require("../config/ui/menu");
32
const {getUnsafeWindow} = require("../utils/scope-util");
43
const {DocumentHook} = require("../hook/document-hook");
54
const {initConfig, getGlobalConfig} = require("../config/config");
@@ -16,18 +15,12 @@ function init() {
1615
// 增加可视化的配置
1716
registerMenu();
1817

19-
// 增加一个测试断点
20-
// const jsonpDebugger = new Debugger("test", true, "match-regexp", /xxxxx/);
21-
// getGlobalConfig().addDebugger(jsonpDebugger);
22-
2318
// 为document增加hook点
24-
const unsafeWindow = getUnsafeWindow();
25-
new DocumentHook(unsafeWindow.document).addHook();
19+
new DocumentHook(getUnsafeWindow().document).addHook();
2620

2721
if (GM_getValue("js-script-hook-open-configuration")) {
2822
GM_setValue("js-script-hook-open-configuration", false);
29-
const configurationComponent = new ConfigurationComponent();
30-
configurationComponent.show();
23+
show();
3124
}
3225

3326
}

0 commit comments

Comments
 (0)