refactor: consume Commonlib as a package

This commit is contained in:
vorotamoroz
2026-07-17 11:13:16 +00:00
parent 6475d32769
commit a721d3b602
665 changed files with 3438 additions and 31592 deletions
+10 -3
View File
@@ -1,4 +1,4 @@
import { eventHub } from "@lib/hub/hub";
import { createLiveSyncEventHub } from "@vrtmrz/livesync-commonlib/compat/hub/hub";
// import type ObsidianLiveSyncPlugin from "../main";
export const EVENT_PLUGIN_LOADED = "plugin-loaded";
@@ -43,5 +43,12 @@ declare global {
}
}
export * from "@lib/events/coreEvents.ts";
export { eventHub };
export * from "@vrtmrz/livesync-commonlib/compat/events/coreEvents";
/**
* Self-hosted LiveSync's host event channel.
*
* Commonlib does not own a process-global channel. Each LiveSync host context is
* composed with this channel while legacy host UI modules migrate to context.events.
*/
export const eventHub = createLiveSyncEventHub();