mirror of
https://github.com/HKUDS/nanobot.git
synced 2026-09-04 10:11:46 +03:00
perf(tui): reduce cold-start latency
This commit is contained in:
@@ -112,6 +112,14 @@ export class RuntimeControls {
|
||||
void this.load().catch(() => {})
|
||||
}
|
||||
|
||||
useApiConnection(apiUrl: string, apiToken: string): void {
|
||||
this.options.apiUrl = apiUrl
|
||||
this.options.apiToken = apiToken
|
||||
this.controlsLoaded = false
|
||||
this.controlsLoadedAt = 0
|
||||
this.preload()
|
||||
}
|
||||
|
||||
updateWorkspaceScope(scope: WorkspaceScopePayload): void {
|
||||
this.scope = scope
|
||||
this.render()
|
||||
|
||||
Reference in New Issue
Block a user