feat(nbstore): add blob sync storage (#10752)

This commit is contained in:
EYHN
2025-03-14 18:05:54 +08:00
committed by GitHub
parent a2eb3fe1b2
commit 05200ad7b7
56 changed files with 1441 additions and 404 deletions

View File

@@ -5,6 +5,7 @@ import { Doc as YDoc, encodeStateAsUpdate } from 'yjs';
import {
IndexedDBBlobStorage,
IndexedDBBlobSyncStorage,
IndexedDBDocStorage,
IndexedDBDocSyncStorage,
} from '../impls/idb';
@@ -138,8 +139,15 @@ test('blob', async () => {
type: 'workspace',
});
const blobSync = new IndexedDBBlobSyncStorage({
id: 'ws1',
flavour: 'a',
type: 'workspace',
});
const peerA = new SpaceStorage({
blob: a,
blobSync,
});
const peerB = new SpaceStorage({
blob: b,