mirror of
https://github.com/vrtmrz/obsidian-livesync.git
synced 2026-07-25 05:53:00 +00:00
Refine P2P and manual setup workflows
This commit is contained in:
@@ -23,6 +23,10 @@ export type ConfiguredSettings = {
|
||||
export type CoreReadiness = {
|
||||
databaseReady: boolean;
|
||||
appReady: boolean;
|
||||
configured?: boolean;
|
||||
remoteType?: string;
|
||||
settingVersion?: number;
|
||||
suspended?: boolean;
|
||||
};
|
||||
|
||||
export type ReplicationAttempt = CoreReadiness & {
|
||||
@@ -348,9 +352,14 @@ export async function waitForLiveSyncCoreReady(
|
||||
[
|
||||
"(async()=>{",
|
||||
"const core=app.plugins.plugins['obsidian-livesync'].core;",
|
||||
"const settings=core.services.setting.currentSettings();",
|
||||
"return JSON.stringify({",
|
||||
"databaseReady:core.services.database.isDatabaseReady(),",
|
||||
"appReady:core.services.appLifecycle.isReady(),",
|
||||
"configured:settings?.isConfigured===true,",
|
||||
"remoteType:settings?.remoteType??'',",
|
||||
"settingVersion:settings?.settingVersion,",
|
||||
"suspended:core.services.appLifecycle.isSuspended(),",
|
||||
"});",
|
||||
"})()",
|
||||
].join(""),
|
||||
|
||||
Reference in New Issue
Block a user