refactor: improve code maintainability

This commit is contained in:
Erzbir
2026-06-15 22:06:13 +08:00
parent 72346d78d2
commit fdec0aafa1
12 changed files with 421 additions and 291 deletions
+4 -2
View File
@@ -6,10 +6,12 @@ export class Terminal {
}
registerRefresh(func) {
if (typeof func !== "function") return;
this._refreshFunctions.push(func);
}
registerInitFunc(func) {
if (typeof func !== "function") return;
this._initFunctions.push(func);
}
@@ -22,5 +24,5 @@ export class Terminal {
}
}
export var terminal = new Terminal();
window.terminal = terminal;
export const terminal = new Terminal();
window.terminal = terminal;