1
0
silverbullet/website/Client Modes.md

33 lines
2.3 KiB
Markdown
Raw Normal View History

2023-09-07 10:47:52 +00:00
SilverBullet currently supports two modes for its client (the part of SilverBullet that runs in the browser):
2023-08-29 19:17:29 +00:00
2023-09-07 10:47:52 +00:00
1. _Online mode_ (the default): keeps all content on the server and only loads content to the client on-demand.
2. _Synced mode_ (offline capable): syncs all content to the client.
2023-08-29 19:17:29 +00:00
2023-09-07 10:47:52 +00:00
You can toggle between these two modes by toggling the 🔄 button in the top bar.
2023-08-29 19:17:29 +00:00
2023-11-27 16:12:47 +00:00
You can switch modes any time and use different modes on different devices.
2023-09-07 10:47:52 +00:00
**Note:** It is technically possible to _switch off online mode_ (and allow synced mode only) by running the SilverBullet server with the `--sync-only` flag (or setting the `SB_SYNC_ONLY` environment variable to something). With this flag on, the sync button will not appear in the UI.
2023-08-29 19:17:29 +00:00
## Online mode
2023-09-07 10:47:52 +00:00
In online mode, all content in your space is kept on the server, and a lot of the heavy lifting (such as indexing of pages) happens on the server as well. Content will only be loaded to the client on-demand.
2023-08-29 19:17:29 +00:00
Advantages:
2023-09-07 10:47:52 +00:00
* **Keeps content on the server**: this mode does not synchronize all your content to your client (browser), making this a better fit for large spaces or for cases where you only need to quickly login to SilverBullet to check something, e.g. on a device you dont usually use. This use case is the reason why this is the default mode.
2023-11-27 16:12:47 +00:00
* **Lighter weight** in terms of memory and CPU use of the client.
2023-08-29 19:17:29 +00:00
Disadvantages:
2023-11-27 16:12:47 +00:00
* **Requires a working network connection** to the server. You can not load pages nor successfully persist changes without it.
* **Higher latency** since more interactions require calls to the server, this may be notable e.g., when completing page names.
2023-08-29 19:17:29 +00:00
## Synced mode
2023-09-02 07:55:03 +00:00
In this mode, all content is synchronized to the client, and all processing happens there. The server effectively acts as a “dumb data store.” All SilverBullet functionality is available even when there is no network connection available.
2023-08-29 19:17:29 +00:00
Advantages:
2023-09-02 07:55:03 +00:00
* **100% offline capable**: disconnect your client from the network, shutdown the server, and everything still works. Changes synchronize automatically once a network connection is re-established.
2023-08-29 19:17:29 +00:00
* **Lower latency**: all actions are performed locally in the client, which in most cases will be faster
Disadvantages:
* **Synchronizes all content onto your client**: using disk space and an initially large bulk of network traffic to download everything.