We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 52097e1 commit 972f16eCopy full SHA for 972f16e
README.md
@@ -51,6 +51,8 @@ const hostId = await peer.createRoom({
51
52
// Or, join room
53
await peer.joinRoom('host-peer-id'); // Rejects if connection fails or times out
54
+
55
+// Interact with the synced storage
56
const currentState = peer.getStorage;
57
peer.updateStorageArray('players', 'add', { username: 'PeerEnjoyer4', level: 2 }); // Special method to enable simultaneous storage updates for arrays
58
peer.updateStorage('latestPlayer', 'PeerEnjoyer4'); // Regular synced storage update
0 commit comments