@dfinity/zod-schemas 3.0.0-next-2025-10-22.4 → 3.0.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/README.md +3 -3
- package/package.json +5 -5
package/README.md
CHANGED
|
@@ -62,7 +62,7 @@ schema.parse("https://example.com"); // Valid
|
|
|
62
62
|
schema.parse("wss://example.com"); // Valid
|
|
63
63
|
schema.parse("http://localhost"); // Invalid if allowHttpLocally is false
|
|
64
64
|
|
|
65
|
-
[:link: Source](https://github.com/dfinity/
|
|
65
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/zod-schemas/src/url.ts#L27)
|
|
66
66
|
|
|
67
67
|
### :wrench: Constants
|
|
68
68
|
|
|
@@ -87,7 +87,7 @@ const result = PrincipalTextSchema.safeParse("aaaaa-aa");
|
|
|
87
87
|
console.log(result.success); // true or false
|
|
88
88
|
```
|
|
89
89
|
|
|
90
|
-
[:link: Source](https://github.com/dfinity/
|
|
90
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/zod-schemas/src/principal.ts#L16)
|
|
91
91
|
|
|
92
92
|
#### :gear: UrlSchema
|
|
93
93
|
|
|
@@ -102,6 +102,6 @@ Examples:
|
|
|
102
102
|
UrlSchema.parse("https://example.com"); // Valid
|
|
103
103
|
UrlSchema.parse("http://127.0.0.1"); // Valid (localhost exception)
|
|
104
104
|
|
|
105
|
-
[:link: Source](https://github.com/dfinity/
|
|
105
|
+
[:link: Source](https://github.com/dfinity/icp-js-canisters/tree/main/packages/zod-schemas/src/url.ts#L64)
|
|
106
106
|
|
|
107
107
|
<!-- TSDOC_END -->
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dfinity/zod-schemas",
|
|
3
|
-
"version": "3.0.0
|
|
3
|
+
"version": "3.0.0",
|
|
4
4
|
"description": "A collection of reusable Zod schemas and validators for common data patterns in ICP applications",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"type": "module",
|
|
@@ -33,11 +33,11 @@
|
|
|
33
33
|
},
|
|
34
34
|
"repository": {
|
|
35
35
|
"type": "git",
|
|
36
|
-
"url": "git+https://github.com/dfinity/
|
|
36
|
+
"url": "git+https://github.com/dfinity/icp-js-canisters.git",
|
|
37
37
|
"directory": "packages/zod-schemas"
|
|
38
38
|
},
|
|
39
39
|
"bugs": {
|
|
40
|
-
"url": "https://github.com/dfinity/
|
|
40
|
+
"url": "https://github.com/dfinity/icp-js-canisters"
|
|
41
41
|
},
|
|
42
42
|
"keywords": [
|
|
43
43
|
"internet computer",
|
|
@@ -61,6 +61,6 @@
|
|
|
61
61
|
],
|
|
62
62
|
"peerDependencies": {
|
|
63
63
|
"@icp-sdk/core": "*",
|
|
64
|
-
"zod": "
|
|
64
|
+
"zod": "^4"
|
|
65
65
|
}
|
|
66
|
-
}
|
|
66
|
+
}
|