@infra-blocks/zod-utils 0.5.0-alpha.1 → 0.5.0-alpha.3

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.
@@ -1,5 +1,5 @@
1
1
  import { z } from "zod";
2
- declare function csv(): z.ZodDefault<z.ZodPipe<z.ZodString, z.ZodTransform<string[], string>>>;
2
+ declare function csv(): z.ZodPipe<z.ZodString, z.ZodTransform<string[], string>>;
3
3
  declare const zu: {
4
4
  geojson: {
5
5
  (): z.ZodUnion<readonly [z.ZodUnion<readonly [z.ZodObject<{
package/lib/cjs/index.js CHANGED
@@ -4,10 +4,7 @@ exports.zu = void 0;
4
4
  const zod_1 = require("zod");
5
5
  const index_js_1 = require("./json/index.js");
6
6
  const index_js_2 = require("./geojson/index.js");
7
- const csvSchema = zod_1.z
8
- .string()
9
- .transform((str) => str.split(","))
10
- .default([]);
7
+ const csvSchema = zod_1.z.string().transform((str) => str.split(","));
11
8
  function csv() {
12
9
  return csvSchema;
13
10
  }
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AACxB,8CAAuC;AACvC,iDAA6C;AAE7C,MAAM,SAAS,GAAG,OAAC;KAChB,MAAM,EAAE;KACR,SAAS,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;KAClC,OAAO,CAAC,EAAE,CAAC,CAAC;AAEf,SAAS,GAAG;IACV,OAAO,SAAS,CAAC;AACnB,CAAC;AAED,MAAM,EAAE,GAAG;IACT,OAAO,EAAP,kBAAO;IACP,IAAI,EAAJ,eAAI;IACJ,GAAG;CACJ,CAAC;AAEO,gBAAE"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AACxB,8CAAuC;AACvC,iDAA6C;AAE7C,MAAM,SAAS,GAAG,OAAC,CAAC,MAAM,EAAE,CAAC,SAAS,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;AAEhE,SAAS,GAAG;IACV,OAAO,SAAS,CAAC;AACnB,CAAC;AAED,MAAM,EAAE,GAAG;IACT,OAAO,EAAP,kBAAO;IACP,IAAI,EAAJ,eAAI;IACJ,GAAG;CACJ,CAAC;AAEO,gBAAE"}
@@ -1,5 +1,5 @@
1
1
  import { z } from "zod";
2
- declare function csv(): z.ZodDefault<z.ZodPipe<z.ZodString, z.ZodTransform<string[], string>>>;
2
+ declare function csv(): z.ZodPipe<z.ZodString, z.ZodTransform<string[], string>>;
3
3
  declare const zu: {
4
4
  geojson: {
5
5
  (): z.ZodUnion<readonly [z.ZodUnion<readonly [z.ZodObject<{
package/lib/esm/index.js CHANGED
@@ -1,10 +1,7 @@
1
1
  import { z } from "zod";
2
2
  import { json } from "./json/index.js";
3
3
  import { geojson } from "./geojson/index.js";
4
- const csvSchema = z
5
- .string()
6
- .transform((str) => str.split(","))
7
- .default([]);
4
+ const csvSchema = z.string().transform((str) => str.split(","));
8
5
  function csv() {
9
6
  return csvSchema;
10
7
  }
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,IAAI,EAAE,MAAM,iBAAiB,CAAC;AACvC,OAAO,EAAE,OAAO,EAAE,MAAM,oBAAoB,CAAC;AAE7C,MAAM,SAAS,GAAG,CAAC;KAChB,MAAM,EAAE;KACR,SAAS,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;KAClC,OAAO,CAAC,EAAE,CAAC,CAAC;AAEf,SAAS,GAAG;IACV,OAAO,SAAS,CAAC;AACnB,CAAC;AAED,MAAM,EAAE,GAAG;IACT,OAAO;IACP,IAAI;IACJ,GAAG;CACJ,CAAC;AAEF,OAAO,EAAE,EAAE,EAAE,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,IAAI,EAAE,MAAM,iBAAiB,CAAC;AACvC,OAAO,EAAE,OAAO,EAAE,MAAM,oBAAoB,CAAC;AAE7C,MAAM,SAAS,GAAG,CAAC,CAAC,MAAM,EAAE,CAAC,SAAS,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;AAEhE,SAAS,GAAG;IACV,OAAO,SAAS,CAAC;AACnB,CAAC;AAED,MAAM,EAAE,GAAG;IACT,OAAO;IACP,IAAI;IACJ,GAAG;CACJ,CAAC;AAEF,OAAO,EAAE,EAAE,EAAE,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@infra-blocks/zod-utils",
3
- "version": "0.5.0-alpha.1",
3
+ "version": "0.5.0-alpha.3",
4
4
  "description": "Extensions to the zod package.",
5
5
  "keywords": [
6
6
  "zod",