@awsless/json 0.0.7 → 0.0.8
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/index.cjs +9 -0
- package/dist/index.js +9 -0
- package/package.json +7 -4
package/dist/index.cjs
CHANGED
|
@@ -113,9 +113,18 @@ var $url = {
|
|
|
113
113
|
stringify: (v) => v.toString()
|
|
114
114
|
};
|
|
115
115
|
|
|
116
|
+
// src/type/duration.ts
|
|
117
|
+
var import_duration = require("@awsless/duration");
|
|
118
|
+
var $duration = {
|
|
119
|
+
is: (v) => v instanceof import_duration.Duration,
|
|
120
|
+
parse: (v) => new import_duration.Duration(BigInt(v)),
|
|
121
|
+
stringify: (v) => v.value.toString()
|
|
122
|
+
};
|
|
123
|
+
|
|
116
124
|
// src/type/index.ts
|
|
117
125
|
var baseTypes = {
|
|
118
126
|
$undefined,
|
|
127
|
+
$duration,
|
|
119
128
|
$infinity,
|
|
120
129
|
$bigfloat,
|
|
121
130
|
$bigint,
|
package/dist/index.js
CHANGED
|
@@ -78,9 +78,18 @@ var $url = {
|
|
|
78
78
|
stringify: (v) => v.toString()
|
|
79
79
|
};
|
|
80
80
|
|
|
81
|
+
// src/type/duration.ts
|
|
82
|
+
import { Duration } from "@awsless/duration";
|
|
83
|
+
var $duration = {
|
|
84
|
+
is: (v) => v instanceof Duration,
|
|
85
|
+
parse: (v) => new Duration(BigInt(v)),
|
|
86
|
+
stringify: (v) => v.value.toString()
|
|
87
|
+
};
|
|
88
|
+
|
|
81
89
|
// src/type/index.ts
|
|
82
90
|
var baseTypes = {
|
|
83
91
|
$undefined,
|
|
92
|
+
$duration,
|
|
84
93
|
$infinity,
|
|
85
94
|
$bigfloat,
|
|
86
95
|
$bigint,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@awsless/json",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.8",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"keywords": [
|
|
@@ -17,7 +17,8 @@
|
|
|
17
17
|
"RegExp",
|
|
18
18
|
"Uint8Array",
|
|
19
19
|
"Binary",
|
|
20
|
-
"undefined"
|
|
20
|
+
"undefined",
|
|
21
|
+
"extendable"
|
|
21
22
|
],
|
|
22
23
|
"repository": {
|
|
23
24
|
"type": "git",
|
|
@@ -40,10 +41,12 @@
|
|
|
40
41
|
}
|
|
41
42
|
},
|
|
42
43
|
"peerDependencies": {
|
|
43
|
-
"@awsless/big-float": "^0.0.4"
|
|
44
|
+
"@awsless/big-float": "^0.0.4",
|
|
45
|
+
"@awsless/duration": "^0.0.2"
|
|
44
46
|
},
|
|
45
47
|
"devDependencies": {
|
|
46
|
-
"@awsless/big-float": "^0.0.4"
|
|
48
|
+
"@awsless/big-float": "^0.0.4",
|
|
49
|
+
"@awsless/duration": "^0.0.2"
|
|
47
50
|
},
|
|
48
51
|
"scripts": {
|
|
49
52
|
"test": "pnpm code test",
|