Skip to content

Commit 2791961

Browse files
committed
docs: update OffSync page for v1.5.0 UI redesign
- Remove outdated video imports (old UI recordings) - Add Enabling/Disabling OffSync section with dialog flow - Rewrite Configuration tab: Database ID + SQL snippet + Push Notifications - Add Metrics tab section (active devices, upload/download bytes) - Update intro to reflect 4-tab layout
1 parent f5073e9 commit 2791961

File tree

1 file changed

+28
-17
lines changed

1 file changed

+28
-17
lines changed

sqlite-cloud/platform/offsync.mdx

Lines changed: 28 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,6 @@ status: publish
66
slug: offsync
77
---
88

9-
import VideoPlayer from '@commons-components/Video/VideoPlayer.astro';
10-
import enableSync from '@docs-website-assets/introduction/video/dashboard_sqlite_sync_enabling.mp4';
11-
import connectionUrlSync from '@docs-website-assets/introduction/video/dashboard_sync_connection_url.mp4';
12-
import devicesSync from '@docs-website-assets/introduction/video/dashboard_sync_devices.mp4';
13-
149
import Callout from "@commons-components/Information/Callout.astro";
1510

1611
OffSync is a powerful SQLite Cloud feature that enables true **local-first** data synchronization for your applications. Powered by the <a href="https://github.com/sqliteai/sqlite-sync" target="_blank">SQLite Sync</a> extension, it allows you to build robust, offline-capable applications where data is stored and processed on edge devices and seamlessly synchronized with a central SQLite Cloud database.
@@ -31,35 +26,51 @@ OffSync extends standard SQLite tables with built-in support for offline work an
3126
When combined with [Row-Level Security (RLS)](/docs/rls), OffSync allows you to build secure, multi-tenant applications where each user's data is safely isolated, both on the edge and in the cloud.
3227

3328

34-
---
29+
---
3530

3631
## Configuring OffSync
3732

38-
You can enable and manage OffSync for your databases directly from the SQLite Cloud dashboard.
39-
Below are the main steps:
33+
You can enable and manage OffSync for your databases directly from the SQLite Cloud dashboard.
34+
The OffSync panel has four tabs: **Sync Tables**, **Configuration**, **Devices**, and **Metrics**.
35+
36+
### Enabling and Disabling OffSync
37+
38+
When OffSync is not yet active for a database, the panel shows a brief explanation and an **Enable OffSync** button. Clicking it opens a confirmation dialog; after confirming, the database is registered with the sync service and the tabbed view appears.
39+
40+
To disable OffSync, click the **Disable OffSync** button in the top-right corner of the panel and confirm the action in the dialog that appears.
4041

4142
### Enable Tables for Synchronization
42-
From the **Sync Tables** tab, select which tables in your database you want to keep synchronized.
43+
44+
From the **Sync Tables** tab, select which tables in your database you want to keep synchronized.
4345
Once enabled, all changes to those tables will automatically sync with connected devices.
4446

45-
<VideoPlayer src={enableSync} />
47+
### Configuration Tab
4648

49+
The **Configuration** tab contains two sub-sections:
4750

48-
### Get the Connection String
49-
In the **Configuration** tab, copy the connection string.
50-
Use this in your application to initialize OffSync and connect your local SQLite database with SQLite Cloud.
51+
**Database ID** — A read-only field showing the unique identifier for your OffSync-enabled database, with a copy button for convenience. Use this ID in your application to initialize the sync connection:
5152

52-
<VideoPlayer src={connectionUrlSync} />
53+
```sql
54+
SELECT cloudsync_network_init('<database-id>');
55+
```
5356

57+
**Push Notifications** — Configure an Expo access token to enable push notifications when using `sqlite-sync-react-native` in push mode. The tab shows the current notification status: **Working**, **Paused**, or **Not working**.
5458

5559
### Manage Connected Devices
56-
In the **Devices** tab, you can view all devices currently connected to your database.
57-
Here you can check their sync status and remove devices if needed.
5860

59-
<VideoPlayer src={devicesSync} />
61+
In the **Devices** tab, you can view all devices currently connected to your database.
62+
Here you can check their sync status and remove devices if needed.
6063

6164
<Callout type="note" title="Matching Schemas and Tables">
6265
For OffSync to work correctly, the list of tables configured for synchronization—and their corresponding schemas—must be identical in both your local SQLite database and your SQLite Cloud database.
6366
</Callout>
6467

68+
### Metrics Tab
69+
70+
The **Metrics** tab provides visibility into daily and cumulative usage for your OffSync-enabled database:
71+
72+
- **Active devices** — number of devices that have synced within the period
73+
- **Upload bytes** — data sent from devices to SQLite Cloud
74+
- **Download bytes** — data sent from SQLite Cloud to devices
75+
6576
Once enabled, any changes made to the selected tables via the SQLite Sync extension will be automatically synchronized with your SQLite Cloud database.

0 commit comments

Comments
 (0)