@loro-dev/flock-wasm 0.1.2 → 0.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1281 -6
- package/base64/flock_wasm.js +9 -4
- package/base64/index.d.ts +11 -6
- package/base64/index.js +11 -6
- package/base64/wasm.js +1 -1
- package/bundler/flock_wasm.d.ts +9 -4
- package/bundler/flock_wasm_bg.js +9 -4
- package/bundler/flock_wasm_bg.wasm +0 -0
- package/bundler/index.d.ts +11 -6
- package/bundler/index.js +11 -6
- package/nodejs/flock_wasm.d.ts +9 -4
- package/nodejs/flock_wasm.js +9 -4
- package/nodejs/flock_wasm_bg.wasm +0 -0
- package/nodejs/index.d.ts +11 -6
- package/nodejs/index.js +11 -6
- package/package.json +2 -1
- package/web/flock_wasm.d.ts +9 -4
- package/web/flock_wasm.js +9 -4
- package/web/flock_wasm_bg.wasm +0 -0
- package/web/index.d.ts +11 -6
- package/web/index.js +11 -6
package/bundler/flock_wasm.d.ts
CHANGED
|
@@ -120,8 +120,11 @@ export class RawFlock {
|
|
|
120
120
|
/**
|
|
121
121
|
* Returns the inclusive version vector for this flock.
|
|
122
122
|
*
|
|
123
|
-
*
|
|
124
|
-
*
|
|
123
|
+
* This vector tracks max seen clocks per peer for the current process
|
|
124
|
+
* lifetime (open/import/local writes), including peers that may no longer
|
|
125
|
+
* own visible entries.
|
|
126
|
+
*
|
|
127
|
+
* Use this vector for completeness checks, not incremental export baselines.
|
|
125
128
|
*
|
|
126
129
|
* # Errors
|
|
127
130
|
*
|
|
@@ -231,8 +234,10 @@ export class RawFlock {
|
|
|
231
234
|
/**
|
|
232
235
|
* Returns the exclusive version vector for this flock.
|
|
233
236
|
*
|
|
234
|
-
*
|
|
235
|
-
*
|
|
237
|
+
* This vector only includes peers that currently own at least one visible
|
|
238
|
+
* entry (excluding tombstones and shadowed entries).
|
|
239
|
+
*
|
|
240
|
+
* Use this vector as the baseline for incremental export/replication.
|
|
236
241
|
*
|
|
237
242
|
* # Errors
|
|
238
243
|
*
|
package/bundler/flock_wasm_bg.js
CHANGED
|
@@ -438,8 +438,11 @@ export class RawFlock {
|
|
|
438
438
|
/**
|
|
439
439
|
* Returns the inclusive version vector for this flock.
|
|
440
440
|
*
|
|
441
|
-
*
|
|
442
|
-
*
|
|
441
|
+
* This vector tracks max seen clocks per peer for the current process
|
|
442
|
+
* lifetime (open/import/local writes), including peers that may no longer
|
|
443
|
+
* own visible entries.
|
|
444
|
+
*
|
|
445
|
+
* Use this vector for completeness checks, not incremental export baselines.
|
|
443
446
|
*
|
|
444
447
|
* # Errors
|
|
445
448
|
*
|
|
@@ -625,8 +628,10 @@ export class RawFlock {
|
|
|
625
628
|
/**
|
|
626
629
|
* Returns the exclusive version vector for this flock.
|
|
627
630
|
*
|
|
628
|
-
*
|
|
629
|
-
*
|
|
631
|
+
* This vector only includes peers that currently own at least one visible
|
|
632
|
+
* entry (excluding tombstones and shadowed entries).
|
|
633
|
+
*
|
|
634
|
+
* Use this vector as the baseline for incremental export/replication.
|
|
630
635
|
*
|
|
631
636
|
* # Errors
|
|
632
637
|
*
|
|
Binary file
|
package/bundler/index.d.ts
CHANGED
|
@@ -156,18 +156,23 @@ export declare class Flock {
|
|
|
156
156
|
getEntry(key: KeyPart[]): EntryInfo | undefined;
|
|
157
157
|
merge(other: Flock): void;
|
|
158
158
|
/**
|
|
159
|
-
* Returns the exclusive version vector
|
|
160
|
-
*
|
|
161
|
-
*
|
|
159
|
+
* Returns the exclusive/visible version vector.
|
|
160
|
+
*
|
|
161
|
+
* Only peers that currently own at least one visible entry are included.
|
|
162
|
+
* This vector is consistent with current visible state and is the correct
|
|
163
|
+
* baseline for incremental export/replication.
|
|
162
164
|
*
|
|
163
165
|
* Use this version when sending to other peers for incremental sync.
|
|
164
166
|
*/
|
|
165
167
|
version(): VersionVector;
|
|
166
168
|
/**
|
|
167
|
-
* Returns the inclusive version vector
|
|
168
|
-
*
|
|
169
|
+
* Returns the inclusive/max-seen version vector.
|
|
170
|
+
*
|
|
171
|
+
* Tracks max seen clocks per peer for this process lifetime
|
|
172
|
+
* (open/import/local writes), including peers that may no longer own visible
|
|
173
|
+
* entries.
|
|
169
174
|
*
|
|
170
|
-
* Use this version
|
|
175
|
+
* Use this version for completeness checks, not incremental export baselines.
|
|
171
176
|
*/
|
|
172
177
|
inclusiveVersion(): VersionVector;
|
|
173
178
|
private exportJsonInternal;
|
package/bundler/index.js
CHANGED
|
@@ -650,9 +650,11 @@ export class Flock {
|
|
|
650
650
|
void this.inner.merge(other.inner);
|
|
651
651
|
}
|
|
652
652
|
/**
|
|
653
|
-
* Returns the exclusive version vector
|
|
654
|
-
*
|
|
655
|
-
*
|
|
653
|
+
* Returns the exclusive/visible version vector.
|
|
654
|
+
*
|
|
655
|
+
* Only peers that currently own at least one visible entry are included.
|
|
656
|
+
* This vector is consistent with current visible state and is the correct
|
|
657
|
+
* baseline for incremental export/replication.
|
|
656
658
|
*
|
|
657
659
|
* Use this version when sending to other peers for incremental sync.
|
|
658
660
|
*/
|
|
@@ -660,10 +662,13 @@ export class Flock {
|
|
|
660
662
|
return decodeVersionVectorFromRaw(this.inner.version());
|
|
661
663
|
}
|
|
662
664
|
/**
|
|
663
|
-
* Returns the inclusive version vector
|
|
664
|
-
*
|
|
665
|
+
* Returns the inclusive/max-seen version vector.
|
|
666
|
+
*
|
|
667
|
+
* Tracks max seen clocks per peer for this process lifetime
|
|
668
|
+
* (open/import/local writes), including peers that may no longer own visible
|
|
669
|
+
* entries.
|
|
665
670
|
*
|
|
666
|
-
* Use this version
|
|
671
|
+
* Use this version for completeness checks, not incremental export baselines.
|
|
667
672
|
*/
|
|
668
673
|
inclusiveVersion() {
|
|
669
674
|
return decodeVersionVectorFromRaw(this.inner.inclusiveVersion());
|
package/nodejs/flock_wasm.d.ts
CHANGED
|
@@ -120,8 +120,11 @@ export class RawFlock {
|
|
|
120
120
|
/**
|
|
121
121
|
* Returns the inclusive version vector for this flock.
|
|
122
122
|
*
|
|
123
|
-
*
|
|
124
|
-
*
|
|
123
|
+
* This vector tracks max seen clocks per peer for the current process
|
|
124
|
+
* lifetime (open/import/local writes), including peers that may no longer
|
|
125
|
+
* own visible entries.
|
|
126
|
+
*
|
|
127
|
+
* Use this vector for completeness checks, not incremental export baselines.
|
|
125
128
|
*
|
|
126
129
|
* # Errors
|
|
127
130
|
*
|
|
@@ -231,8 +234,10 @@ export class RawFlock {
|
|
|
231
234
|
/**
|
|
232
235
|
* Returns the exclusive version vector for this flock.
|
|
233
236
|
*
|
|
234
|
-
*
|
|
235
|
-
*
|
|
237
|
+
* This vector only includes peers that currently own at least one visible
|
|
238
|
+
* entry (excluding tombstones and shadowed entries).
|
|
239
|
+
*
|
|
240
|
+
* Use this vector as the baseline for incremental export/replication.
|
|
236
241
|
*
|
|
237
242
|
* # Errors
|
|
238
243
|
*
|
package/nodejs/flock_wasm.js
CHANGED
|
@@ -434,8 +434,11 @@ class RawFlock {
|
|
|
434
434
|
/**
|
|
435
435
|
* Returns the inclusive version vector for this flock.
|
|
436
436
|
*
|
|
437
|
-
*
|
|
438
|
-
*
|
|
437
|
+
* This vector tracks max seen clocks per peer for the current process
|
|
438
|
+
* lifetime (open/import/local writes), including peers that may no longer
|
|
439
|
+
* own visible entries.
|
|
440
|
+
*
|
|
441
|
+
* Use this vector for completeness checks, not incremental export baselines.
|
|
439
442
|
*
|
|
440
443
|
* # Errors
|
|
441
444
|
*
|
|
@@ -621,8 +624,10 @@ class RawFlock {
|
|
|
621
624
|
/**
|
|
622
625
|
* Returns the exclusive version vector for this flock.
|
|
623
626
|
*
|
|
624
|
-
*
|
|
625
|
-
*
|
|
627
|
+
* This vector only includes peers that currently own at least one visible
|
|
628
|
+
* entry (excluding tombstones and shadowed entries).
|
|
629
|
+
*
|
|
630
|
+
* Use this vector as the baseline for incremental export/replication.
|
|
626
631
|
*
|
|
627
632
|
* # Errors
|
|
628
633
|
*
|
|
Binary file
|
package/nodejs/index.d.ts
CHANGED
|
@@ -156,18 +156,23 @@ export declare class Flock {
|
|
|
156
156
|
getEntry(key: KeyPart[]): EntryInfo | undefined;
|
|
157
157
|
merge(other: Flock): void;
|
|
158
158
|
/**
|
|
159
|
-
* Returns the exclusive version vector
|
|
160
|
-
*
|
|
161
|
-
*
|
|
159
|
+
* Returns the exclusive/visible version vector.
|
|
160
|
+
*
|
|
161
|
+
* Only peers that currently own at least one visible entry are included.
|
|
162
|
+
* This vector is consistent with current visible state and is the correct
|
|
163
|
+
* baseline for incremental export/replication.
|
|
162
164
|
*
|
|
163
165
|
* Use this version when sending to other peers for incremental sync.
|
|
164
166
|
*/
|
|
165
167
|
version(): VersionVector;
|
|
166
168
|
/**
|
|
167
|
-
* Returns the inclusive version vector
|
|
168
|
-
*
|
|
169
|
+
* Returns the inclusive/max-seen version vector.
|
|
170
|
+
*
|
|
171
|
+
* Tracks max seen clocks per peer for this process lifetime
|
|
172
|
+
* (open/import/local writes), including peers that may no longer own visible
|
|
173
|
+
* entries.
|
|
169
174
|
*
|
|
170
|
-
* Use this version
|
|
175
|
+
* Use this version for completeness checks, not incremental export baselines.
|
|
171
176
|
*/
|
|
172
177
|
inclusiveVersion(): VersionVector;
|
|
173
178
|
private exportJsonInternal;
|
package/nodejs/index.js
CHANGED
|
@@ -655,9 +655,11 @@ class Flock {
|
|
|
655
655
|
void this.inner.merge(other.inner);
|
|
656
656
|
}
|
|
657
657
|
/**
|
|
658
|
-
* Returns the exclusive version vector
|
|
659
|
-
*
|
|
660
|
-
*
|
|
658
|
+
* Returns the exclusive/visible version vector.
|
|
659
|
+
*
|
|
660
|
+
* Only peers that currently own at least one visible entry are included.
|
|
661
|
+
* This vector is consistent with current visible state and is the correct
|
|
662
|
+
* baseline for incremental export/replication.
|
|
661
663
|
*
|
|
662
664
|
* Use this version when sending to other peers for incremental sync.
|
|
663
665
|
*/
|
|
@@ -665,10 +667,13 @@ class Flock {
|
|
|
665
667
|
return decodeVersionVectorFromRaw(this.inner.version());
|
|
666
668
|
}
|
|
667
669
|
/**
|
|
668
|
-
* Returns the inclusive version vector
|
|
669
|
-
*
|
|
670
|
+
* Returns the inclusive/max-seen version vector.
|
|
671
|
+
*
|
|
672
|
+
* Tracks max seen clocks per peer for this process lifetime
|
|
673
|
+
* (open/import/local writes), including peers that may no longer own visible
|
|
674
|
+
* entries.
|
|
670
675
|
*
|
|
671
|
-
* Use this version
|
|
676
|
+
* Use this version for completeness checks, not incremental export baselines.
|
|
672
677
|
*/
|
|
673
678
|
inclusiveVersion() {
|
|
674
679
|
return decodeVersionVectorFromRaw(this.inner.inclusiveVersion());
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@loro-dev/flock-wasm",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.4",
|
|
4
4
|
"description": "WASM bindings for flock-rs.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"sideEffects": false,
|
|
@@ -30,6 +30,7 @@
|
|
|
30
30
|
"devDependencies": {
|
|
31
31
|
"@types/node": "^22.0.0",
|
|
32
32
|
"typescript": "^5.9.0",
|
|
33
|
+
"vite-plugin-wasm": "^3.5.0",
|
|
33
34
|
"vitest": "^3.2.4"
|
|
34
35
|
},
|
|
35
36
|
"license": "AGPL-3.0-only",
|
package/web/flock_wasm.d.ts
CHANGED
|
@@ -120,8 +120,11 @@ export class RawFlock {
|
|
|
120
120
|
/**
|
|
121
121
|
* Returns the inclusive version vector for this flock.
|
|
122
122
|
*
|
|
123
|
-
*
|
|
124
|
-
*
|
|
123
|
+
* This vector tracks max seen clocks per peer for the current process
|
|
124
|
+
* lifetime (open/import/local writes), including peers that may no longer
|
|
125
|
+
* own visible entries.
|
|
126
|
+
*
|
|
127
|
+
* Use this vector for completeness checks, not incremental export baselines.
|
|
125
128
|
*
|
|
126
129
|
* # Errors
|
|
127
130
|
*
|
|
@@ -231,8 +234,10 @@ export class RawFlock {
|
|
|
231
234
|
/**
|
|
232
235
|
* Returns the exclusive version vector for this flock.
|
|
233
236
|
*
|
|
234
|
-
*
|
|
235
|
-
*
|
|
237
|
+
* This vector only includes peers that currently own at least one visible
|
|
238
|
+
* entry (excluding tombstones and shadowed entries).
|
|
239
|
+
*
|
|
240
|
+
* Use this vector as the baseline for incremental export/replication.
|
|
236
241
|
*
|
|
237
242
|
* # Errors
|
|
238
243
|
*
|
package/web/flock_wasm.js
CHANGED
|
@@ -430,8 +430,11 @@ export class RawFlock {
|
|
|
430
430
|
/**
|
|
431
431
|
* Returns the inclusive version vector for this flock.
|
|
432
432
|
*
|
|
433
|
-
*
|
|
434
|
-
*
|
|
433
|
+
* This vector tracks max seen clocks per peer for the current process
|
|
434
|
+
* lifetime (open/import/local writes), including peers that may no longer
|
|
435
|
+
* own visible entries.
|
|
436
|
+
*
|
|
437
|
+
* Use this vector for completeness checks, not incremental export baselines.
|
|
435
438
|
*
|
|
436
439
|
* # Errors
|
|
437
440
|
*
|
|
@@ -617,8 +620,10 @@ export class RawFlock {
|
|
|
617
620
|
/**
|
|
618
621
|
* Returns the exclusive version vector for this flock.
|
|
619
622
|
*
|
|
620
|
-
*
|
|
621
|
-
*
|
|
623
|
+
* This vector only includes peers that currently own at least one visible
|
|
624
|
+
* entry (excluding tombstones and shadowed entries).
|
|
625
|
+
*
|
|
626
|
+
* Use this vector as the baseline for incremental export/replication.
|
|
622
627
|
*
|
|
623
628
|
* # Errors
|
|
624
629
|
*
|
package/web/flock_wasm_bg.wasm
CHANGED
|
Binary file
|
package/web/index.d.ts
CHANGED
|
@@ -156,18 +156,23 @@ export declare class Flock {
|
|
|
156
156
|
getEntry(key: KeyPart[]): EntryInfo | undefined;
|
|
157
157
|
merge(other: Flock): void;
|
|
158
158
|
/**
|
|
159
|
-
* Returns the exclusive version vector
|
|
160
|
-
*
|
|
161
|
-
*
|
|
159
|
+
* Returns the exclusive/visible version vector.
|
|
160
|
+
*
|
|
161
|
+
* Only peers that currently own at least one visible entry are included.
|
|
162
|
+
* This vector is consistent with current visible state and is the correct
|
|
163
|
+
* baseline for incremental export/replication.
|
|
162
164
|
*
|
|
163
165
|
* Use this version when sending to other peers for incremental sync.
|
|
164
166
|
*/
|
|
165
167
|
version(): VersionVector;
|
|
166
168
|
/**
|
|
167
|
-
* Returns the inclusive version vector
|
|
168
|
-
*
|
|
169
|
+
* Returns the inclusive/max-seen version vector.
|
|
170
|
+
*
|
|
171
|
+
* Tracks max seen clocks per peer for this process lifetime
|
|
172
|
+
* (open/import/local writes), including peers that may no longer own visible
|
|
173
|
+
* entries.
|
|
169
174
|
*
|
|
170
|
-
* Use this version
|
|
175
|
+
* Use this version for completeness checks, not incremental export baselines.
|
|
171
176
|
*/
|
|
172
177
|
inclusiveVersion(): VersionVector;
|
|
173
178
|
private exportJsonInternal;
|
package/web/index.js
CHANGED
|
@@ -650,9 +650,11 @@ export class Flock {
|
|
|
650
650
|
void this.inner.merge(other.inner);
|
|
651
651
|
}
|
|
652
652
|
/**
|
|
653
|
-
* Returns the exclusive version vector
|
|
654
|
-
*
|
|
655
|
-
*
|
|
653
|
+
* Returns the exclusive/visible version vector.
|
|
654
|
+
*
|
|
655
|
+
* Only peers that currently own at least one visible entry are included.
|
|
656
|
+
* This vector is consistent with current visible state and is the correct
|
|
657
|
+
* baseline for incremental export/replication.
|
|
656
658
|
*
|
|
657
659
|
* Use this version when sending to other peers for incremental sync.
|
|
658
660
|
*/
|
|
@@ -660,10 +662,13 @@ export class Flock {
|
|
|
660
662
|
return decodeVersionVectorFromRaw(this.inner.version());
|
|
661
663
|
}
|
|
662
664
|
/**
|
|
663
|
-
* Returns the inclusive version vector
|
|
664
|
-
*
|
|
665
|
+
* Returns the inclusive/max-seen version vector.
|
|
666
|
+
*
|
|
667
|
+
* Tracks max seen clocks per peer for this process lifetime
|
|
668
|
+
* (open/import/local writes), including peers that may no longer own visible
|
|
669
|
+
* entries.
|
|
665
670
|
*
|
|
666
|
-
* Use this version
|
|
671
|
+
* Use this version for completeness checks, not incremental export baselines.
|
|
667
672
|
*/
|
|
668
673
|
inclusiveVersion() {
|
|
669
674
|
return decodeVersionVectorFromRaw(this.inner.inclusiveVersion());
|