forceSyncNow static method

Future<void> forceSyncNow({
  1. ForceSyncListener? callback,
})

Get the current WebSocket connection status.

Migration Note: Migrated from platform channels to native Dart implementation. Uses RealtimeRepository to get current connection state. Offline: runs a catch-up sync now. With no callback it is fire-and-forget (a no-op when offline is disabled or not logged in); with a callback it reports that the catch-up was accepted and started (its progress and outcome arrive on the SyncListener phase callbacks), or rejects with a public OfflineSyncError code (ERROR_OFFLINE_SYNC_IN_PROGRESS / ERROR_OFFLINE_SYNC_COOLDOWN / ERROR_OFFLINE_DISABLED) or the not-logged-in code.

Implementation

static Future<void> forceSyncNow({ForceSyncListener? callback}) =>
    OfflineRuntime.instance.forceSyncNow(callback: callback);