@evolu/common 8.5.0 → 8.6.0
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/dist/src/Array.d.ts +170 -97
- package/dist/src/Array.d.ts.map +1 -1
- package/dist/src/Array.js +67 -42
- package/dist/src/Assert.d.ts +233 -30
- package/dist/src/Assert.d.ts.map +1 -1
- package/dist/src/Assert.js +150 -30
- package/dist/src/BigInt.d.ts +3 -3
- package/dist/src/BigInt.js +3 -3
- package/dist/src/Brand.d.ts +7 -7
- package/dist/src/Buffer.d.ts +12 -4
- package/dist/src/Buffer.d.ts.map +1 -1
- package/dist/src/Cache.d.ts +8 -3
- package/dist/src/Cache.d.ts.map +1 -1
- package/dist/src/Cache.js +8 -3
- package/dist/src/Callbacks.d.ts +8 -4
- package/dist/src/Callbacks.d.ts.map +1 -1
- package/dist/src/Console.d.ts +45 -30
- package/dist/src/Console.d.ts.map +1 -1
- package/dist/src/Console.js +32 -21
- package/dist/src/Crypto.d.ts +13 -8
- package/dist/src/Crypto.d.ts.map +1 -1
- package/dist/src/Crypto.js +6 -3
- package/dist/src/Eq.d.ts +107 -58
- package/dist/src/Eq.d.ts.map +1 -1
- package/dist/src/Eq.js +308 -112
- package/dist/src/Function.d.ts +54 -24
- package/dist/src/Function.d.ts.map +1 -1
- package/dist/src/Function.js +34 -17
- package/dist/src/Http.d.ts +52 -19
- package/dist/src/Http.d.ts.map +1 -1
- package/dist/src/Identicon.d.ts +9 -4
- package/dist/src/Identicon.d.ts.map +1 -1
- package/dist/src/Identicon.js +9 -4
- package/dist/src/LockManager.d.ts +12 -10
- package/dist/src/LockManager.d.ts.map +1 -1
- package/dist/src/Lookup.d.ts +4 -2
- package/dist/src/Lookup.d.ts.map +1 -1
- package/dist/src/Lookup.js +4 -2
- package/dist/src/Number.d.ts +28 -24
- package/dist/src/Number.d.ts.map +1 -1
- package/dist/src/Number.js +16 -17
- package/dist/src/Object.d.ts +89 -47
- package/dist/src/Object.d.ts.map +1 -1
- package/dist/src/Object.js +88 -41
- package/dist/src/Option.d.ts +14 -5
- package/dist/src/Option.d.ts.map +1 -1
- package/dist/src/Option.js +14 -5
- package/dist/src/Order.d.ts +12 -12
- package/dist/src/Order.js +12 -12
- package/dist/src/Platform.d.ts +2 -2
- package/dist/src/Random.d.ts +7 -4
- package/dist/src/Random.d.ts.map +1 -1
- package/dist/src/Redacted.d.ts +13 -6
- package/dist/src/Redacted.d.ts.map +1 -1
- package/dist/src/Redacted.js +4 -2
- package/dist/src/Ref.d.ts +4 -4
- package/dist/src/Relation.d.ts +5 -7
- package/dist/src/Relation.d.ts.map +1 -1
- package/dist/src/Resource.d.ts +27 -12
- package/dist/src/Resource.d.ts.map +1 -1
- package/dist/src/Result.d.ts +258 -114
- package/dist/src/Result.d.ts.map +1 -1
- package/dist/src/Result.js +71 -34
- package/dist/src/Schedule.d.ts +233 -116
- package/dist/src/Schedule.d.ts.map +1 -1
- package/dist/src/Schedule.js +204 -110
- package/dist/src/Set.d.ts +43 -24
- package/dist/src/Set.d.ts.map +1 -1
- package/dist/src/Set.js +25 -13
- package/dist/src/Sqlite.d.ts +4 -4
- package/dist/src/Sqlite.d.ts.map +1 -1
- package/dist/src/Sqlite.js +9 -8
- package/dist/src/Task.d.ts +441 -212
- package/dist/src/Task.d.ts.map +1 -1
- package/dist/src/Task.js +238 -115
- package/dist/src/Test.d.ts +10 -4
- package/dist/src/Test.d.ts.map +1 -1
- package/dist/src/Test.js +10 -4
- package/dist/src/Time.d.ts +27 -17
- package/dist/src/Time.d.ts.map +1 -1
- package/dist/src/Time.js +16 -6
- package/dist/src/Type.d.ts +1096 -387
- package/dist/src/Type.d.ts.map +1 -1
- package/dist/src/Type.js +1046 -372
- package/dist/src/Types.d.ts +95 -40
- package/dist/src/Types.d.ts.map +1 -1
- package/dist/src/Types.js +13 -4
- package/dist/src/WebSocket.d.ts +14 -6
- package/dist/src/WebSocket.d.ts.map +1 -1
- package/dist/src/Worker.d.ts +10 -6
- package/dist/src/Worker.d.ts.map +1 -1
- package/dist/src/intl/_en.d.ts +3 -1
- package/dist/src/intl/_en.d.ts.map +1 -1
- package/dist/src/intl/_en.js +17 -3
- package/dist/src/intl/ar.d.ts +3 -1
- package/dist/src/intl/ar.d.ts.map +1 -1
- package/dist/src/intl/ar.js +15 -2
- package/dist/src/intl/bn.d.ts +3 -1
- package/dist/src/intl/bn.d.ts.map +1 -1
- package/dist/src/intl/bn.js +16 -3
- package/dist/src/intl/ca.d.ts +3 -1
- package/dist/src/intl/ca.d.ts.map +1 -1
- package/dist/src/intl/ca.js +16 -3
- package/dist/src/intl/cs.d.ts +3 -1
- package/dist/src/intl/cs.d.ts.map +1 -1
- package/dist/src/intl/cs.js +16 -3
- package/dist/src/intl/da.d.ts +3 -1
- package/dist/src/intl/da.d.ts.map +1 -1
- package/dist/src/intl/da.js +16 -3
- package/dist/src/intl/de.d.ts +3 -1
- package/dist/src/intl/de.d.ts.map +1 -1
- package/dist/src/intl/de.js +16 -3
- package/dist/src/intl/el.d.ts +3 -1
- package/dist/src/intl/el.d.ts.map +1 -1
- package/dist/src/intl/el.js +16 -3
- package/dist/src/intl/es.d.ts +3 -1
- package/dist/src/intl/es.d.ts.map +1 -1
- package/dist/src/intl/es.js +16 -3
- package/dist/src/intl/fa.d.ts +3 -1
- package/dist/src/intl/fa.d.ts.map +1 -1
- package/dist/src/intl/fa.js +16 -3
- package/dist/src/intl/fi.d.ts +3 -1
- package/dist/src/intl/fi.d.ts.map +1 -1
- package/dist/src/intl/fi.js +16 -3
- package/dist/src/intl/fil.d.ts +3 -1
- package/dist/src/intl/fil.d.ts.map +1 -1
- package/dist/src/intl/fil.js +16 -3
- package/dist/src/intl/fr.d.ts +3 -1
- package/dist/src/intl/fr.d.ts.map +1 -1
- package/dist/src/intl/fr.js +16 -3
- package/dist/src/intl/he.d.ts +3 -1
- package/dist/src/intl/he.d.ts.map +1 -1
- package/dist/src/intl/he.js +16 -3
- package/dist/src/intl/hi.d.ts +3 -1
- package/dist/src/intl/hi.d.ts.map +1 -1
- package/dist/src/intl/hi.js +16 -3
- package/dist/src/intl/hr.d.ts +3 -1
- package/dist/src/intl/hr.d.ts.map +1 -1
- package/dist/src/intl/hr.js +16 -3
- package/dist/src/intl/hu.d.ts +2 -1
- package/dist/src/intl/hu.d.ts.map +1 -1
- package/dist/src/intl/hu.js +15 -3
- package/dist/src/intl/id.d.ts +3 -1
- package/dist/src/intl/id.d.ts.map +1 -1
- package/dist/src/intl/id.js +16 -3
- package/dist/src/intl/it.d.ts +3 -1
- package/dist/src/intl/it.d.ts.map +1 -1
- package/dist/src/intl/it.js +16 -3
- package/dist/src/intl/ja.d.ts +3 -1
- package/dist/src/intl/ja.d.ts.map +1 -1
- package/dist/src/intl/ja.js +16 -3
- package/dist/src/intl/ko.d.ts +3 -1
- package/dist/src/intl/ko.d.ts.map +1 -1
- package/dist/src/intl/ko.js +16 -3
- package/dist/src/intl/ml.d.ts +3 -1
- package/dist/src/intl/ml.d.ts.map +1 -1
- package/dist/src/intl/ml.js +16 -3
- package/dist/src/intl/mr.d.ts +3 -1
- package/dist/src/intl/mr.d.ts.map +1 -1
- package/dist/src/intl/mr.js +16 -3
- package/dist/src/intl/ms.d.ts +3 -1
- package/dist/src/intl/ms.d.ts.map +1 -1
- package/dist/src/intl/ms.js +15 -2
- package/dist/src/intl/nb.d.ts +2 -1
- package/dist/src/intl/nb.d.ts.map +1 -1
- package/dist/src/intl/nb.js +14 -2
- package/dist/src/intl/nl.d.ts +3 -1
- package/dist/src/intl/nl.d.ts.map +1 -1
- package/dist/src/intl/nl.js +16 -3
- package/dist/src/intl/pa.d.ts +3 -1
- package/dist/src/intl/pa.d.ts.map +1 -1
- package/dist/src/intl/pa.js +16 -3
- package/dist/src/intl/pl.d.ts +2 -0
- package/dist/src/intl/pl.d.ts.map +1 -1
- package/dist/src/intl/pl.js +15 -2
- package/dist/src/intl/pt-BR.d.ts +3 -1
- package/dist/src/intl/pt-BR.d.ts.map +1 -1
- package/dist/src/intl/pt-BR.js +16 -3
- package/dist/src/intl/pt.d.ts +3 -1
- package/dist/src/intl/pt.d.ts.map +1 -1
- package/dist/src/intl/pt.js +15 -2
- package/dist/src/intl/ro.d.ts +3 -1
- package/dist/src/intl/ro.d.ts.map +1 -1
- package/dist/src/intl/ro.js +16 -3
- package/dist/src/intl/sk.d.ts +3 -1
- package/dist/src/intl/sk.d.ts.map +1 -1
- package/dist/src/intl/sk.js +15 -2
- package/dist/src/intl/sl.d.ts +3 -1
- package/dist/src/intl/sl.d.ts.map +1 -1
- package/dist/src/intl/sl.js +16 -3
- package/dist/src/intl/sv.d.ts +3 -1
- package/dist/src/intl/sv.d.ts.map +1 -1
- package/dist/src/intl/sv.js +16 -3
- package/dist/src/intl/sw.d.ts +1 -0
- package/dist/src/intl/sw.d.ts.map +1 -1
- package/dist/src/intl/sw.js +14 -2
- package/dist/src/intl/ta.d.ts +3 -1
- package/dist/src/intl/ta.d.ts.map +1 -1
- package/dist/src/intl/ta.js +16 -3
- package/dist/src/intl/te.d.ts +3 -1
- package/dist/src/intl/te.d.ts.map +1 -1
- package/dist/src/intl/te.js +16 -3
- package/dist/src/intl/th.d.ts +3 -1
- package/dist/src/intl/th.d.ts.map +1 -1
- package/dist/src/intl/th.js +16 -3
- package/dist/src/intl/tr.d.ts +3 -1
- package/dist/src/intl/tr.d.ts.map +1 -1
- package/dist/src/intl/tr.js +16 -3
- package/dist/src/intl/uk.d.ts +3 -1
- package/dist/src/intl/uk.d.ts.map +1 -1
- package/dist/src/intl/uk.js +16 -3
- package/dist/src/intl/ur.d.ts +3 -1
- package/dist/src/intl/ur.d.ts.map +1 -1
- package/dist/src/intl/ur.js +15 -2
- package/dist/src/intl/vi.d.ts +3 -1
- package/dist/src/intl/vi.d.ts.map +1 -1
- package/dist/src/intl/vi.js +16 -3
- package/dist/src/intl/zh-CN.d.ts +3 -1
- package/dist/src/intl/zh-CN.d.ts.map +1 -1
- package/dist/src/intl/zh-CN.js +16 -3
- package/dist/src/intl/zh-TW.d.ts +3 -1
- package/dist/src/intl/zh-TW.d.ts.map +1 -1
- package/dist/src/intl/zh-TW.js +16 -3
- package/dist/src/local-first/Evolu.d.ts +47 -24
- package/dist/src/local-first/Evolu.d.ts.map +1 -1
- package/dist/src/local-first/Owner.d.ts +10 -7
- package/dist/src/local-first/Owner.d.ts.map +1 -1
- package/dist/src/local-first/Owner.js +10 -7
- package/dist/src/local-first/Protocol.d.ts +5 -5
- package/dist/src/local-first/Protocol.js +5 -5
- package/dist/src/local-first/Query.d.ts +34 -21
- package/dist/src/local-first/Query.d.ts.map +1 -1
- package/dist/src/local-first/Query.js +25 -13
- package/dist/src/local-first/Relay.d.ts +12 -5
- package/dist/src/local-first/Relay.d.ts.map +1 -1
- package/dist/src/local-first/Schema.d.ts +19 -11
- package/dist/src/local-first/Schema.d.ts.map +1 -1
- package/dist/src/local-first/Schema.js +11 -6
- package/dist/src/local-first/Storage.d.ts +4 -2
- package/dist/src/local-first/Storage.d.ts.map +1 -1
- package/package.json +3 -4
- package/src/Array.ts +170 -97
- package/src/Assert.ts +336 -31
- package/src/BigInt.ts +3 -3
- package/src/Brand.ts +7 -7
- package/src/Buffer.ts +12 -4
- package/src/Cache.ts +8 -3
- package/src/Callbacks.ts +8 -4
- package/src/Console.ts +45 -30
- package/src/Crypto.ts +13 -8
- package/src/Eq.ts +450 -122
- package/src/Function.ts +54 -24
- package/src/Http.ts +52 -19
- package/src/Identicon.ts +9 -4
- package/src/LockManager.ts +12 -10
- package/src/Lookup.ts +4 -2
- package/src/Number.ts +28 -24
- package/src/Object.ts +115 -49
- package/src/Option.ts +14 -5
- package/src/Order.ts +12 -12
- package/src/Platform.ts +2 -2
- package/src/Random.ts +7 -4
- package/src/Redacted.ts +13 -6
- package/src/Ref.ts +4 -4
- package/src/Relation.ts +5 -7
- package/src/Resource.ts +27 -12
- package/src/Result.ts +258 -114
- package/src/Schedule.ts +233 -116
- package/src/Set.ts +43 -24
- package/src/Sqlite.ts +9 -8
- package/src/Task.ts +441 -212
- package/src/Test.ts +10 -4
- package/src/Time.ts +27 -17
- package/src/Type.ts +2077 -620
- package/src/Types.ts +108 -40
- package/src/WebSocket.ts +14 -6
- package/src/Worker.ts +10 -6
- package/src/intl/_en.ts +20 -4
- package/src/intl/ar.ts +17 -2
- package/src/intl/bn.ts +19 -4
- package/src/intl/ca.ts +19 -4
- package/src/intl/cs.ts +19 -4
- package/src/intl/da.ts +19 -4
- package/src/intl/de.ts +19 -4
- package/src/intl/el.ts +19 -4
- package/src/intl/es.ts +19 -4
- package/src/intl/fa.ts +19 -4
- package/src/intl/fi.ts +19 -4
- package/src/intl/fil.ts +19 -4
- package/src/intl/fr.ts +19 -4
- package/src/intl/he.ts +19 -4
- package/src/intl/hi.ts +19 -4
- package/src/intl/hr.ts +19 -4
- package/src/intl/hu.ts +18 -4
- package/src/intl/id.ts +19 -4
- package/src/intl/it.ts +19 -4
- package/src/intl/ja.ts +19 -4
- package/src/intl/ko.ts +19 -4
- package/src/intl/ml.ts +19 -4
- package/src/intl/mr.ts +19 -4
- package/src/intl/ms.ts +17 -2
- package/src/intl/nb.ts +16 -2
- package/src/intl/nl.ts +19 -4
- package/src/intl/pa.ts +19 -4
- package/src/intl/pl.ts +18 -2
- package/src/intl/pt-BR.ts +19 -4
- package/src/intl/pt.ts +17 -2
- package/src/intl/ro.ts +19 -4
- package/src/intl/sk.ts +17 -2
- package/src/intl/sl.ts +19 -4
- package/src/intl/sv.ts +19 -4
- package/src/intl/sw.ts +15 -2
- package/src/intl/ta.ts +19 -4
- package/src/intl/te.ts +19 -4
- package/src/intl/th.ts +19 -4
- package/src/intl/tr.ts +19 -4
- package/src/intl/uk.ts +19 -4
- package/src/intl/ur.ts +17 -2
- package/src/intl/vi.ts +19 -3
- package/src/intl/zh-CN.ts +19 -4
- package/src/intl/zh-TW.ts +19 -4
- package/src/local-first/Evolu.ts +47 -24
- package/src/local-first/Owner.ts +10 -7
- package/src/local-first/Protocol.ts +5 -5
- package/src/local-first/Query.ts +34 -21
- package/src/local-first/Relay.ts +12 -5
- package/src/local-first/Schema.ts +19 -11
- package/src/local-first/Storage.ts +4 -2
package/dist/src/Lookup.js
CHANGED
|
@@ -126,6 +126,8 @@ export const createLookupSet = ({ lookup, values, }) => {
|
|
|
126
126
|
*
|
|
127
127
|
* ```ts
|
|
128
128
|
* import {
|
|
129
|
+
* assertEqual,
|
|
130
|
+
* assertSame,
|
|
129
131
|
* createLookupMap,
|
|
130
132
|
* structuralLookup,
|
|
131
133
|
* type StructuralLookupKey,
|
|
@@ -150,8 +152,8 @@ export const createLookupSet = ({ lookup, values, }) => {
|
|
|
150
152
|
* };
|
|
151
153
|
* byFilter.set(cachedFilter, "cached");
|
|
152
154
|
*
|
|
153
|
-
*
|
|
154
|
-
*
|
|
155
|
+
* assertEqual(byFilter.get(equivalentFilter), "cached");
|
|
156
|
+
* assertSame(byFilter.getKey(equivalentFilter), cachedFilter);
|
|
155
157
|
* ```
|
|
156
158
|
*
|
|
157
159
|
* @see {@link StructuralKey}
|
package/dist/src/Number.d.ts
CHANGED
|
@@ -22,6 +22,7 @@ export type Int1To100 = Int1To99 | 100;
|
|
|
22
22
|
*
|
|
23
23
|
* ```ts
|
|
24
24
|
* import {
|
|
25
|
+
* assertEqual,
|
|
25
26
|
* NonNegativeInt,
|
|
26
27
|
* type Int0To100OrNonNegativeInt,
|
|
27
28
|
* } from "@evolu/common";
|
|
@@ -29,8 +30,8 @@ export type Int1To100 = Int1To99 | 100;
|
|
|
29
30
|
* const literal: Int0To100OrNonNegativeInt = 10;
|
|
30
31
|
* const validated: Int0To100OrNonNegativeInt = NonNegativeInt.orThrow(101);
|
|
31
32
|
*
|
|
32
|
-
*
|
|
33
|
-
*
|
|
33
|
+
* assertEqual(literal, 10);
|
|
34
|
+
* assertEqual(validated, 101);
|
|
34
35
|
* ```
|
|
35
36
|
*/
|
|
36
37
|
export type Int0To100OrNonNegativeInt = 0 | Int1To100 | NonNegativeInt;
|
|
@@ -43,13 +44,17 @@ export type Int0To100OrNonNegativeInt = 0 | Int1To100 | NonNegativeInt;
|
|
|
43
44
|
* ### Example
|
|
44
45
|
*
|
|
45
46
|
* ```ts
|
|
46
|
-
* import {
|
|
47
|
+
* import {
|
|
48
|
+
* assertEqual,
|
|
49
|
+
* PositiveInt,
|
|
50
|
+
* type Int1To100OrPositiveInt,
|
|
51
|
+
* } from "@evolu/common";
|
|
47
52
|
*
|
|
48
53
|
* const literal: Int1To100OrPositiveInt = 10;
|
|
49
54
|
* const validated: Int1To100OrPositiveInt = PositiveInt.orThrow(101);
|
|
50
55
|
*
|
|
51
|
-
*
|
|
52
|
-
*
|
|
56
|
+
* assertEqual(literal, 10);
|
|
57
|
+
* assertEqual(validated, 101);
|
|
53
58
|
* ```
|
|
54
59
|
*/
|
|
55
60
|
export type Int1To100OrPositiveInt = Int1To100 | PositiveInt;
|
|
@@ -62,12 +67,12 @@ export type Int1To100OrPositiveInt = Int1To100 | PositiveInt;
|
|
|
62
67
|
* ### Example
|
|
63
68
|
*
|
|
64
69
|
* ```ts
|
|
65
|
-
* import { Ratio, jitter } from "@evolu/common";
|
|
70
|
+
* import { Ratio, assertType, jitter } from "@evolu/common";
|
|
66
71
|
*
|
|
67
72
|
* const readableJitter = jitter("50%");
|
|
68
73
|
* const computedJitter = jitter(Ratio.orThrow(0.5));
|
|
69
74
|
*
|
|
70
|
-
*
|
|
75
|
+
* assertType<typeof computedJitter, typeof readableJitter>();
|
|
71
76
|
* ```
|
|
72
77
|
*/
|
|
73
78
|
export type Percentage = PercentageLiteral | Ratio;
|
|
@@ -91,12 +96,12 @@ export declare const clamp: (min: number, max: number) => (n: number) => number;
|
|
|
91
96
|
* ### Example
|
|
92
97
|
*
|
|
93
98
|
* ```ts
|
|
94
|
-
* import { isBetween } from "@evolu/common";
|
|
99
|
+
* import { assertFalse, assertTrue, isBetween } from "@evolu/common";
|
|
95
100
|
*
|
|
96
101
|
* const isBetween10And20 = isBetween(10, 20);
|
|
97
102
|
*
|
|
98
|
-
*
|
|
99
|
-
*
|
|
103
|
+
* assertTrue(isBetween10And20(20));
|
|
104
|
+
* assertFalse(isBetween10And20(25));
|
|
100
105
|
* ```
|
|
101
106
|
*/
|
|
102
107
|
export declare const isBetween: (min: number, max: number) => Predicate<number>;
|
|
@@ -113,27 +118,26 @@ export declare const max: <T extends number>(...values: [T, ...ReadonlyArray<T>]
|
|
|
113
118
|
*
|
|
114
119
|
* ```ts
|
|
115
120
|
* import {
|
|
121
|
+
* assertErr,
|
|
122
|
+
* assertOk,
|
|
116
123
|
* computeBalancedBuckets,
|
|
117
124
|
* NonNegativeInt,
|
|
118
125
|
* PositiveInt,
|
|
119
126
|
* } from "@evolu/common";
|
|
120
127
|
*
|
|
121
|
-
*
|
|
122
|
-
*
|
|
123
|
-
*
|
|
124
|
-
*
|
|
125
|
-
* PositiveInt.orThrow(2),
|
|
126
|
-
* ),
|
|
127
|
-
* [4, 7, 10],
|
|
128
|
+
* const balanced = computeBalancedBuckets(
|
|
129
|
+
* NonNegativeInt.orThrow(10),
|
|
130
|
+
* PositiveInt.orThrow(3),
|
|
131
|
+
* PositiveInt.orThrow(2),
|
|
128
132
|
* );
|
|
129
|
-
*
|
|
130
|
-
*
|
|
131
|
-
*
|
|
132
|
-
*
|
|
133
|
-
*
|
|
134
|
-
* ),
|
|
135
|
-
* 6,
|
|
133
|
+
* assertOk(balanced, [4, 7, 10]);
|
|
134
|
+
*
|
|
135
|
+
* const insufficient = computeBalancedBuckets(
|
|
136
|
+
* NonNegativeInt.orThrow(5),
|
|
137
|
+
* PositiveInt.orThrow(3),
|
|
138
|
+
* PositiveInt.orThrow(2),
|
|
136
139
|
* );
|
|
140
|
+
* assertErr(insufficient, 6);
|
|
137
141
|
* ```
|
|
138
142
|
*/
|
|
139
143
|
export declare const computeBalancedBuckets: (numberOfItems: NonNegativeInt,
|
package/dist/src/Number.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Number.d.ts","sour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BAAsB,kBAClB,cAAc;AAE7B,kBAAkB;;AAGlB,iBAAiB;8OAEhB,MAAM,CAAC,qBAAqB,CAAC,WAAW,CAAC,EAAE,WAAW,CAoBxD,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,cAAc,6rBAG1B,CAAC;AACF,MAAM,MAAM,cAAc,GAAG,OAAO,cAAc,CAAC,MAAM,CAAC;AAE1D,oFAAoF;AACpF,eAAO,MAAM,WAAW,UAAW,cAAc,KAAG,WAMnD,CAAC"}
|
package/dist/src/Number.js
CHANGED
|
@@ -30,12 +30,12 @@ export const clamp = (min, max) => (n) => Math.min(Math.max(n, min), max);
|
|
|
30
30
|
* ### Example
|
|
31
31
|
*
|
|
32
32
|
* ```ts
|
|
33
|
-
* import { isBetween } from "@evolu/common";
|
|
33
|
+
* import { assertFalse, assertTrue, isBetween } from "@evolu/common";
|
|
34
34
|
*
|
|
35
35
|
* const isBetween10And20 = isBetween(10, 20);
|
|
36
36
|
*
|
|
37
|
-
*
|
|
38
|
-
*
|
|
37
|
+
* assertTrue(isBetween10And20(20));
|
|
38
|
+
* assertFalse(isBetween10And20(25));
|
|
39
39
|
* ```
|
|
40
40
|
*/
|
|
41
41
|
export const isBetween = (min, max) => (value) => value >= min && value <= max;
|
|
@@ -52,27 +52,26 @@ export const max = (...values) => values.reduce((a, b) => (a > b ? a : b));
|
|
|
52
52
|
*
|
|
53
53
|
* ```ts
|
|
54
54
|
* import {
|
|
55
|
+
* assertErr,
|
|
56
|
+
* assertOk,
|
|
55
57
|
* computeBalancedBuckets,
|
|
56
58
|
* NonNegativeInt,
|
|
57
59
|
* PositiveInt,
|
|
58
60
|
* } from "@evolu/common";
|
|
59
61
|
*
|
|
60
|
-
*
|
|
61
|
-
*
|
|
62
|
-
*
|
|
63
|
-
*
|
|
64
|
-
* PositiveInt.orThrow(2),
|
|
65
|
-
* ),
|
|
66
|
-
* [4, 7, 10],
|
|
62
|
+
* const balanced = computeBalancedBuckets(
|
|
63
|
+
* NonNegativeInt.orThrow(10),
|
|
64
|
+
* PositiveInt.orThrow(3),
|
|
65
|
+
* PositiveInt.orThrow(2),
|
|
67
66
|
* );
|
|
68
|
-
*
|
|
69
|
-
*
|
|
70
|
-
*
|
|
71
|
-
*
|
|
72
|
-
*
|
|
73
|
-
* ),
|
|
74
|
-
* 6,
|
|
67
|
+
* assertOk(balanced, [4, 7, 10]);
|
|
68
|
+
*
|
|
69
|
+
* const insufficient = computeBalancedBuckets(
|
|
70
|
+
* NonNegativeInt.orThrow(5),
|
|
71
|
+
* PositiveInt.orThrow(3),
|
|
72
|
+
* PositiveInt.orThrow(2),
|
|
75
73
|
* );
|
|
74
|
+
* assertErr(insufficient, 6);
|
|
76
75
|
* ```
|
|
77
76
|
*/
|
|
78
77
|
export const computeBalancedBuckets = (numberOfItems,
|
package/dist/src/Object.d.ts
CHANGED
|
@@ -8,32 +8,53 @@
|
|
|
8
8
|
* types (e.g., in {@link mapObject}).
|
|
9
9
|
*/
|
|
10
10
|
export type ReadonlyRecord<K extends keyof any, V> = Readonly<Record<K, V>>;
|
|
11
|
+
/** An Object representation recognized by {@link getObjectKind}. */
|
|
12
|
+
export type ObjectKind = "Array" | "Date" | "Map" | "Object" | "Set" | "Uint8Array" | "Unsupported";
|
|
11
13
|
/**
|
|
12
|
-
*
|
|
14
|
+
* Classifies Object representations supported by Evolu's structural data APIs.
|
|
15
|
+
*
|
|
16
|
+
* Plain Objects are classified from their prototype without reading their
|
|
17
|
+
* properties, including `Symbol.toStringTag`.
|
|
18
|
+
*
|
|
19
|
+
* ### Example
|
|
20
|
+
*
|
|
21
|
+
* ```ts
|
|
22
|
+
* import { assertEqual, getObjectKind } from "@evolu/common";
|
|
13
23
|
*
|
|
14
|
-
*
|
|
15
|
-
*
|
|
16
|
-
*
|
|
17
|
-
*
|
|
24
|
+
* assertEqual(getObjectKind({}), "Object");
|
|
25
|
+
* assertEqual(getObjectKind(new Map()), "Map");
|
|
26
|
+
* assertEqual(getObjectKind(/value/u), "Unsupported");
|
|
27
|
+
* ```
|
|
28
|
+
*/
|
|
29
|
+
export declare const getObjectKind: (value: object) => ObjectKind;
|
|
30
|
+
/**
|
|
31
|
+
* Checks if a value is a plain object (e.g., created with `{}` or `Object`).
|
|
18
32
|
*
|
|
19
|
-
*
|
|
20
|
-
*
|
|
21
|
-
*
|
|
33
|
+
* Accepts objects with a `null` prototype. Otherwise, it uses a realm-neutral
|
|
34
|
+
* structural heuristic: the immediate prototype must be a root object with own
|
|
35
|
+
* `hasOwnProperty` and `isPrototypeOf` properties. This recognizes ordinary
|
|
36
|
+
* Objects from another JavaScript realm without relying on prototype identity.
|
|
22
37
|
*
|
|
23
|
-
*
|
|
24
|
-
*
|
|
38
|
+
* A custom root prototype with the same shape can therefore be classified as
|
|
39
|
+
* plain. This function assumes trusted JavaScript and is not a prototype
|
|
40
|
+
* authentication or security boundary. Other custom prototypes, class
|
|
41
|
+
* instances, and built-in objects are rejected.
|
|
25
42
|
*
|
|
26
43
|
* ### Example
|
|
27
44
|
*
|
|
28
45
|
* ```ts
|
|
29
|
-
* import { isPlainObject } from "@evolu/common";
|
|
30
|
-
*
|
|
31
|
-
*
|
|
32
|
-
*
|
|
33
|
-
*
|
|
34
|
-
*
|
|
35
|
-
*
|
|
36
|
-
*
|
|
46
|
+
* import { assertFalse, assertTrue, isPlainObject } from "@evolu/common";
|
|
47
|
+
*
|
|
48
|
+
* class Example {
|
|
49
|
+
* readonly value = "example";
|
|
50
|
+
* }
|
|
51
|
+
*
|
|
52
|
+
* assertTrue(isPlainObject({}));
|
|
53
|
+
* assertTrue(isPlainObject(Object.create(null)));
|
|
54
|
+
* assertFalse(isPlainObject(new Date()));
|
|
55
|
+
* assertFalse(isPlainObject(new Example()));
|
|
56
|
+
* assertFalse(isPlainObject([]));
|
|
57
|
+
* assertFalse(isPlainObject(null));
|
|
37
58
|
* ```
|
|
38
59
|
*/
|
|
39
60
|
export declare const isPlainObject: (value: unknown) => value is Record<string, unknown>;
|
|
@@ -43,11 +64,11 @@ export declare const isPlainObject: (value: unknown) => value is Record<string,
|
|
|
43
64
|
* ### Example
|
|
44
65
|
*
|
|
45
66
|
* ```ts
|
|
46
|
-
* import { isFunction } from "@evolu/common";
|
|
67
|
+
* import { assertFalse, assertTrue, isFunction } from "@evolu/common";
|
|
47
68
|
*
|
|
48
|
-
*
|
|
49
|
-
*
|
|
50
|
-
*
|
|
69
|
+
* assertTrue(isFunction(() => {}));
|
|
70
|
+
* assertTrue(isFunction(function () {}));
|
|
71
|
+
* assertFalse(isFunction({}));
|
|
51
72
|
* ```
|
|
52
73
|
*/
|
|
53
74
|
export declare const isFunction: (value: unknown) => value is globalThis.Function;
|
|
@@ -57,11 +78,11 @@ export declare const isFunction: (value: unknown) => value is globalThis.Functio
|
|
|
57
78
|
* ### Example
|
|
58
79
|
*
|
|
59
80
|
* ```ts
|
|
60
|
-
* import { isIterable } from "@evolu/common";
|
|
81
|
+
* import { assertFalse, assertTrue, isIterable } from "@evolu/common";
|
|
61
82
|
*
|
|
62
|
-
*
|
|
63
|
-
*
|
|
64
|
-
*
|
|
83
|
+
* assertTrue(isIterable([1, 2, 3]));
|
|
84
|
+
* assertTrue(isIterable("abc"));
|
|
85
|
+
* assertFalse(isIterable({}));
|
|
65
86
|
* ```
|
|
66
87
|
*/
|
|
67
88
|
export declare const isIterable: (value: unknown) => value is Iterable<unknown>;
|
|
@@ -72,6 +93,8 @@ export declare const isIterable: (value: unknown) => value is Iterable<unknown>;
|
|
|
72
93
|
*
|
|
73
94
|
* ```ts
|
|
74
95
|
* import {
|
|
96
|
+
* assertEqual,
|
|
97
|
+
* assertType,
|
|
75
98
|
* objectToEntries,
|
|
76
99
|
* type Brand,
|
|
77
100
|
* type ReadonlyRecord,
|
|
@@ -83,8 +106,8 @@ export declare const isIterable: (value: unknown) => value is Iterable<unknown>;
|
|
|
83
106
|
* const users: ReadonlyRecord<UserId, string> = { [userId]: "Alice" };
|
|
84
107
|
* const entries = objectToEntries(users);
|
|
85
108
|
*
|
|
86
|
-
*
|
|
87
|
-
*
|
|
109
|
+
* assertType<ReadonlyArray<[UserId, string]>, typeof entries>();
|
|
110
|
+
* assertEqual(entries, [[userId, "Alice"]]);
|
|
88
111
|
* ```
|
|
89
112
|
*/
|
|
90
113
|
export declare const objectToEntries: <T extends Record<string, any>>(record: T) => ReadonlyArray<[StringKeyOf<T>, T[StringKeyOf<T>]]>;
|
|
@@ -99,6 +122,8 @@ type StringKeyOf<T> = Extract<keyof T, string>;
|
|
|
99
122
|
*
|
|
100
123
|
* ```ts
|
|
101
124
|
* import {
|
|
125
|
+
* assertEqual,
|
|
126
|
+
* assertType,
|
|
102
127
|
* objectFromEntries,
|
|
103
128
|
* type Brand,
|
|
104
129
|
* type ReadonlyRecord,
|
|
@@ -110,8 +135,8 @@ type StringKeyOf<T> = Extract<keyof T, string>;
|
|
|
110
135
|
* ];
|
|
111
136
|
* const users = objectFromEntries(entries);
|
|
112
137
|
*
|
|
113
|
-
*
|
|
114
|
-
*
|
|
138
|
+
* assertType<ReadonlyRecord<UserId, string>, typeof users>();
|
|
139
|
+
* assertEqual(users, { u1: "Alice" });
|
|
115
140
|
* ```
|
|
116
141
|
*/
|
|
117
142
|
export declare const objectFromEntries: <K extends string, V>(entries: Iterable<readonly [K, V]>) => ReadonlyRecord<K, V>;
|
|
@@ -124,17 +149,20 @@ export declare const objectFromEntries: <K extends string, V>(entries: Iterable<
|
|
|
124
149
|
* ### Example
|
|
125
150
|
*
|
|
126
151
|
* ```ts
|
|
127
|
-
* import {
|
|
152
|
+
* import {
|
|
153
|
+
* assertEqual,
|
|
154
|
+
* assertType,
|
|
155
|
+
* objectFrom,
|
|
156
|
+
* type ReadonlyRecord,
|
|
157
|
+
* } from "@evolu/common";
|
|
128
158
|
*
|
|
129
159
|
* const translations = objectFrom(
|
|
130
160
|
* ["en", "fr"] as const,
|
|
131
161
|
* (locale): string => `Hello in ${locale}`,
|
|
132
162
|
* );
|
|
133
163
|
*
|
|
134
|
-
*
|
|
135
|
-
*
|
|
136
|
-
* >();
|
|
137
|
-
* expect(translations).toEqual({
|
|
164
|
+
* assertType<ReadonlyRecord<"en" | "fr", string>, typeof translations>();
|
|
165
|
+
* assertEqual(translations, {
|
|
138
166
|
* en: "Hello in en",
|
|
139
167
|
* fr: "Hello in fr",
|
|
140
168
|
* });
|
|
@@ -174,7 +202,7 @@ export declare const excludeProp: <T extends object, K extends keyof T>(obj: T,
|
|
|
174
202
|
* ### Example
|
|
175
203
|
*
|
|
176
204
|
* ```ts
|
|
177
|
-
* import { createMutableRecord } from "@evolu/common";
|
|
205
|
+
* import { assertEqual, createMutableRecord } from "@evolu/common";
|
|
178
206
|
*
|
|
179
207
|
* const createValuesByKey = (
|
|
180
208
|
* entries: ReadonlyArray<readonly [string, number]>,
|
|
@@ -188,12 +216,13 @@ export declare const excludeProp: <T extends object, K extends keyof T>(obj: T,
|
|
|
188
216
|
* return valuesByKey;
|
|
189
217
|
* };
|
|
190
218
|
*
|
|
191
|
-
*
|
|
219
|
+
* assertEqual(
|
|
192
220
|
* createValuesByKey([
|
|
193
221
|
* ["a", 1],
|
|
194
222
|
* ["b", 2],
|
|
195
223
|
* ]),
|
|
196
|
-
*
|
|
224
|
+
* { a: 1, b: 2 },
|
|
225
|
+
* );
|
|
197
226
|
* ```
|
|
198
227
|
*
|
|
199
228
|
* Note that TypeScript does not model an object's runtime prototype. A plain
|
|
@@ -201,21 +230,34 @@ export declare const excludeProp: <T extends object, K extends keyof T>(obj: T,
|
|
|
201
230
|
* object has a `null` prototype:
|
|
202
231
|
*
|
|
203
232
|
* ```ts
|
|
233
|
+
* import { assertErr, assertTrue, trySync } from "@evolu/common";
|
|
234
|
+
*
|
|
204
235
|
* const values = Object.create(null) as Record<string, number>;
|
|
205
236
|
*
|
|
206
237
|
* // TypeScript accepts the call, but `toString` is undefined at runtime.
|
|
207
|
-
*
|
|
238
|
+
* // oxlint-disable-next-line typescript/no-base-to-string -- Intentionally calls a method missing from the null-prototype value.
|
|
239
|
+
* const result = trySync(() => values.toString());
|
|
240
|
+
* assertErr(result);
|
|
241
|
+
* assertTrue(result.error instanceof TypeError);
|
|
208
242
|
* ```
|
|
209
243
|
*
|
|
210
244
|
* `createMutableRecord` uses the same TypeScript Record representation.
|
|
211
245
|
*
|
|
212
246
|
* ```ts
|
|
213
|
-
* import {
|
|
247
|
+
* import {
|
|
248
|
+
* assertErr,
|
|
249
|
+
* assertTrue,
|
|
250
|
+
* createMutableRecord,
|
|
251
|
+
* trySync,
|
|
252
|
+
* } from "@evolu/common";
|
|
214
253
|
*
|
|
215
254
|
* const values = createMutableRecord<string, number>();
|
|
216
255
|
*
|
|
217
256
|
* // TypeScript accepts the call, but `toString` is undefined at runtime.
|
|
218
|
-
*
|
|
257
|
+
* // oxlint-disable-next-line typescript/no-base-to-string -- Intentionally calls a method missing from the null-prototype value.
|
|
258
|
+
* const result = trySync(() => values.toString());
|
|
259
|
+
* assertErr(result);
|
|
260
|
+
* assertTrue(result.error instanceof TypeError);
|
|
219
261
|
* ```
|
|
220
262
|
*
|
|
221
263
|
* In other words, treat the returned object as string-keyed data rather than
|
|
@@ -251,7 +293,7 @@ export declare const emptyRecord: Readonly<Record<string, never>>;
|
|
|
251
293
|
* ### Example
|
|
252
294
|
*
|
|
253
295
|
* ```ts
|
|
254
|
-
* import { getOwnProp } from "@evolu/common";
|
|
296
|
+
* import { assertEqual, assertType, getOwnProp } from "@evolu/common";
|
|
255
297
|
*
|
|
256
298
|
* interface User {
|
|
257
299
|
* readonly name: string;
|
|
@@ -262,9 +304,9 @@ export declare const emptyRecord: Readonly<Record<string, never>>;
|
|
|
262
304
|
* };
|
|
263
305
|
* const user = getOwnProp(users, "bob");
|
|
264
306
|
*
|
|
265
|
-
*
|
|
266
|
-
*
|
|
267
|
-
*
|
|
307
|
+
* assertType<User | undefined, typeof user>();
|
|
308
|
+
* assertEqual(user, undefined);
|
|
309
|
+
* assertEqual(getOwnProp(users, "toString"), undefined);
|
|
268
310
|
* ```
|
|
269
311
|
*/
|
|
270
312
|
export declare const getOwnProp: <K extends string, V>(record: ReadonlyRecord<K, V>, key: NoInfer<K>) => V | undefined;
|
|
@@ -276,12 +318,12 @@ export declare const getOwnProp: <K extends string, V>(record: ReadonlyRecord<K,
|
|
|
276
318
|
* ### Example
|
|
277
319
|
*
|
|
278
320
|
* ```ts
|
|
279
|
-
* import { createObjectURL } from "@evolu/common";
|
|
321
|
+
* import { assertTrue, createObjectURL } from "@evolu/common";
|
|
280
322
|
*
|
|
281
323
|
* const blob = new Blob(["hello"], { type: "text/plain" });
|
|
282
324
|
* using objectUrl = createObjectURL(blob);
|
|
283
325
|
*
|
|
284
|
-
*
|
|
326
|
+
* assertTrue(objectUrl.url.startsWith("blob:"));
|
|
285
327
|
* // URL.revokeObjectURL is automatically called when the scope ends.
|
|
286
328
|
* ```
|
|
287
329
|
*
|
package/dist/src/Object.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Object.d.ts","sourceRoot":"","sources":["../../src/Object.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH;;;GAGG;AACH,MAAM,MAAM,cAAc,CAAC,CAAC,SAAS,MAAM,GAAG,EAAE,CAAC,IAAI,QAAQ,CAAC,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;AAE5E
|
|
1
|
+
{"version":3,"file":"Object.d.ts","sourceRoot":"","sources":["../../src/Object.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH;;;GAGG;AACH,MAAM,MAAM,cAAc,CAAC,CAAC,SAAS,MAAM,GAAG,EAAE,CAAC,IAAI,QAAQ,CAAC,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;AAE5E,oEAAoE;AACpE,MAAM,MAAM,UAAU,GACpB,OAAO,GAAG,MAAM,GAAG,KAAK,GAAG,QAAQ,GAAG,KAAK,GAAG,YAAY,GAAG,aAAa,CAAC;AAE7E;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,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