@thi.ng/ksuid 2.1.3 → 2.1.6
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/CHANGELOG.md +1 -1
- package/README.md +2 -2
- package/api.d.ts +3 -3
- package/ksuid32.d.ts +1 -1
- package/ksuid32.js +1 -1
- package/ksuid64.d.ts +1 -1
- package/ksuid64.js +1 -1
- package/package.json +16 -16
- package/ulid.d.ts +1 -1
- package/ulid.js +1 -1
package/CHANGELOG.md
CHANGED
package/README.md
CHANGED
|
@@ -87,7 +87,7 @@ node --experimental-repl-await
|
|
|
87
87
|
> const ksuid = await import("@thi.ng/ksuid");
|
|
88
88
|
```
|
|
89
89
|
|
|
90
|
-
Package sizes (gzipped, pre-treeshake): ESM:
|
|
90
|
+
Package sizes (gzipped, pre-treeshake): ESM: 853 bytes
|
|
91
91
|
|
|
92
92
|
## Dependencies
|
|
93
93
|
|
|
@@ -194,4 +194,4 @@ If this project contributes to an academic publication, please cite it as:
|
|
|
194
194
|
|
|
195
195
|
## License
|
|
196
196
|
|
|
197
|
-
© 2020 -
|
|
197
|
+
© 2020 - 2022 Karsten Schmidt // Apache Software License 2.0
|
package/api.d.ts
CHANGED
|
@@ -22,14 +22,14 @@ export interface IKSUID {
|
|
|
22
22
|
* Returns a new baseN encoded ID string for given `epoch` (default: current
|
|
23
23
|
* time) and with all random payload bytes set to 0.
|
|
24
24
|
*
|
|
25
|
-
* @param epoch
|
|
25
|
+
* @param epoch -
|
|
26
26
|
*/
|
|
27
27
|
timeOnly(epoch?: number): string;
|
|
28
28
|
/**
|
|
29
29
|
* Binary version of {@link KSUI.timeOnly}, but returns byte array. The
|
|
30
30
|
* first `epochSize` bytes will contain the timestamp.
|
|
31
31
|
*
|
|
32
|
-
* @param epoch
|
|
32
|
+
* @param epoch -
|
|
33
33
|
*/
|
|
34
34
|
timeOnlyBinary(epoch?: number): Uint8Array;
|
|
35
35
|
/**
|
|
@@ -45,7 +45,7 @@ export interface IKSUID {
|
|
|
45
45
|
* @remarks
|
|
46
46
|
* This operation requires `bigint` support by the host environment.
|
|
47
47
|
*
|
|
48
|
-
* @param id
|
|
48
|
+
* @param id -
|
|
49
49
|
*/
|
|
50
50
|
parse(id: string): {
|
|
51
51
|
epoch: number;
|
package/ksuid32.d.ts
CHANGED
|
@@ -12,7 +12,7 @@ export declare class KSUID32 extends AKSUID {
|
|
|
12
12
|
* Creates and returns a new 32bit epoch KSUID generator instance (w/ second
|
|
13
13
|
* time precision).
|
|
14
14
|
*
|
|
15
|
-
* @param opts
|
|
15
|
+
* @param opts -
|
|
16
16
|
*/
|
|
17
17
|
export declare const defKSUID32: (opts?: Partial<KSUIDOpts> | undefined) => KSUID32;
|
|
18
18
|
//# sourceMappingURL=ksuid32.d.ts.map
|
package/ksuid32.js
CHANGED
package/ksuid64.d.ts
CHANGED
|
@@ -12,7 +12,7 @@ export declare class KSUID64 extends AKSUID {
|
|
|
12
12
|
* Creates and returns a new 64bit epoch KSUID generator instance (w/
|
|
13
13
|
* millisecond time precision).
|
|
14
14
|
*
|
|
15
|
-
* @param opts
|
|
15
|
+
* @param opts -
|
|
16
16
|
*/
|
|
17
17
|
export declare const defKSUID64: (opts?: Partial<KSUIDOpts> | undefined) => KSUID64;
|
|
18
18
|
//# sourceMappingURL=ksuid64.d.ts.map
|
package/ksuid64.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@thi.ng/ksuid",
|
|
3
|
-
"version": "2.1.
|
|
3
|
+
"version": "2.1.6",
|
|
4
4
|
"description": "Configurable K-sortable unique IDs, ULIDs, binary & base-N encoded, 32/48/64bit time resolutions",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"module": "./index.js",
|
|
@@ -35,18 +35,18 @@
|
|
|
35
35
|
"test": "testament test"
|
|
36
36
|
},
|
|
37
37
|
"dependencies": {
|
|
38
|
-
"@thi.ng/base-n": "^2.1
|
|
39
|
-
"@thi.ng/errors": "^2.1.
|
|
40
|
-
"@thi.ng/random": "^3.2.
|
|
41
|
-
"@thi.ng/strings": "^3.3.
|
|
38
|
+
"@thi.ng/base-n": "^2.2.1",
|
|
39
|
+
"@thi.ng/errors": "^2.1.5",
|
|
40
|
+
"@thi.ng/random": "^3.2.5",
|
|
41
|
+
"@thi.ng/strings": "^3.3.3"
|
|
42
42
|
},
|
|
43
43
|
"devDependencies": {
|
|
44
|
-
"@microsoft/api-extractor": "^7.
|
|
45
|
-
"@thi.ng/testament": "^0.2.
|
|
44
|
+
"@microsoft/api-extractor": "^7.19.4",
|
|
45
|
+
"@thi.ng/testament": "^0.2.5",
|
|
46
46
|
"rimraf": "^3.0.2",
|
|
47
47
|
"tools": "^0.0.1",
|
|
48
|
-
"typedoc": "^0.22.
|
|
49
|
-
"typescript": "^4.
|
|
48
|
+
"typedoc": "^0.22.13",
|
|
49
|
+
"typescript": "^4.6.2"
|
|
50
50
|
},
|
|
51
51
|
"keywords": [
|
|
52
52
|
"32bit",
|
|
@@ -82,22 +82,22 @@
|
|
|
82
82
|
],
|
|
83
83
|
"exports": {
|
|
84
84
|
".": {
|
|
85
|
-
"
|
|
85
|
+
"default": "./index.js"
|
|
86
86
|
},
|
|
87
87
|
"./aksuid": {
|
|
88
|
-
"
|
|
88
|
+
"default": "./aksuid.js"
|
|
89
89
|
},
|
|
90
90
|
"./api": {
|
|
91
|
-
"
|
|
91
|
+
"default": "./api.js"
|
|
92
92
|
},
|
|
93
93
|
"./ksuid32": {
|
|
94
|
-
"
|
|
94
|
+
"default": "./ksuid32.js"
|
|
95
95
|
},
|
|
96
96
|
"./ksuid64": {
|
|
97
|
-
"
|
|
97
|
+
"default": "./ksuid64.js"
|
|
98
98
|
},
|
|
99
99
|
"./ulid": {
|
|
100
|
-
"
|
|
100
|
+
"default": "./ulid.js"
|
|
101
101
|
}
|
|
102
102
|
},
|
|
103
103
|
"thi.ng": {
|
|
@@ -109,5 +109,5 @@
|
|
|
109
109
|
"status": "stable",
|
|
110
110
|
"year": 2020
|
|
111
111
|
},
|
|
112
|
-
"gitHead": "
|
|
112
|
+
"gitHead": "5ee1feb590dd935593b1dd4e7f38a3ed3ba64765\n"
|
|
113
113
|
}
|
package/ulid.d.ts
CHANGED