import { SharedSettings } from "https://deno.land/x/earthstar@v10.2.0/src/entries/npm.ts";
Get and set values from a common pool of settings for Earthstar clients, such as an author, shares, share secrets, and servers.
Uses the Storage API, so only clients on the same origin will share the same settings.
Properties
The currently persisted author keypair.
Methods
Add a secret for a share already known to the settings.
Add a server URL to be stored by settings.
Delete all stored settings.
Get a new Peer
preconfigured with shares, secrets, and syncers derived from these settings.
When settings are updated, the peer's replicas and syncers will be updated too.
Fires the given callback when the stored author changes.
Fires the given callback when the stored list of server URLs changes.
Add a new share (and possibly secret) and servers using an Earthstar invitation URL.
Remove a secret from settings.
Remove a server URL from the settings' stored list of servers..