@clementine-solutions/jane-io 1.0.2 → 1.0.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.
- package/dist/index.js +1 -1
- package/package.json +28 -3
- package/dist/test.d.ts +0 -1
- package/dist/test.js +0 -12
package/dist/index.js
CHANGED
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
/* ——— * ————— * ————— * ————— * ————— * ————— * ————— * ————— * ————— * ——— *\
|
|
12
12
|
|* Internal Modules *|
|
|
13
13
|
\* ——— * ————— * ————— * ————— * ————— * ————— * ————— * ————— * ————— * ——— */
|
|
14
|
-
import { createJane } from './core/common';
|
|
14
|
+
import { createJane } from './core/common/index';
|
|
15
15
|
import { defaultPolicy } from './core/common/policy';
|
|
16
16
|
/* ——— * ————— * ————— * ————— * ————— * ————— * ————— * ————— * ————— * ——— *\
|
|
17
17
|
|* Jane *|
|
package/package.json
CHANGED
|
@@ -2,6 +2,32 @@
|
|
|
2
2
|
"name": "@clementine-solutions/jane-io",
|
|
3
3
|
"type": "module",
|
|
4
4
|
"main": "dist/index.js",
|
|
5
|
+
"exports": {
|
|
6
|
+
".": {
|
|
7
|
+
"import": "./dist/index.js",
|
|
8
|
+
"types": "./dist/index.d.ts"
|
|
9
|
+
},
|
|
10
|
+
"./core/common": {
|
|
11
|
+
"import": "./dist/core/common/index.js",
|
|
12
|
+
"types": "./dist/core/common/index.d.ts"
|
|
13
|
+
},
|
|
14
|
+
"./core/common/policy": {
|
|
15
|
+
"import": "./dist/core/common/policy.js",
|
|
16
|
+
"types": "./dist/core/common/policy.d.ts"
|
|
17
|
+
},
|
|
18
|
+
"./core/shapes": {
|
|
19
|
+
"import": "./dist/core/shapes/index.js",
|
|
20
|
+
"types": "./dist/core/shapes/index.d.ts"
|
|
21
|
+
},
|
|
22
|
+
"./core/pipeline": {
|
|
23
|
+
"import": "./dist/core/pipeline/index.js",
|
|
24
|
+
"types": "./dist/core/pipeline/index.d.ts"
|
|
25
|
+
},
|
|
26
|
+
"./core/pipeline/scan": {
|
|
27
|
+
"import": "./dist/core/pipeline/scan.js",
|
|
28
|
+
"types": "./dist/core/pipeline/scan.d.ts"
|
|
29
|
+
}
|
|
30
|
+
},
|
|
5
31
|
"description": "A clarity-first boundary system for shaping, validating, and transforming data with full introspection and policy control.",
|
|
6
32
|
"license": "Apache-2.0",
|
|
7
33
|
"author": "Clementine Solutions <develop.clementine@outlook.com>",
|
|
@@ -16,8 +42,7 @@
|
|
|
16
42
|
"test:ci": "vitest --coverage",
|
|
17
43
|
"docs": "mkdocs serve",
|
|
18
44
|
"build": "tsc -p tsconfig.json",
|
|
19
|
-
"release": "semantic-release"
|
|
20
|
-
"test:smoke": "tsx src/test.ts"
|
|
45
|
+
"release": "semantic-release"
|
|
21
46
|
},
|
|
22
47
|
"devDependencies": {
|
|
23
48
|
"@commitlint/cli": "^20.2.0",
|
|
@@ -83,5 +108,5 @@
|
|
|
83
108
|
"access": "public",
|
|
84
109
|
"registry": "https://registry.npmjs.org/"
|
|
85
110
|
},
|
|
86
|
-
"version": "1.0.
|
|
111
|
+
"version": "1.0.3"
|
|
87
112
|
}
|
package/dist/test.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
package/dist/test.js
DELETED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { jane } from '.';
|
|
2
|
-
const input = {
|
|
3
|
-
name: 'John Doe',
|
|
4
|
-
age: 37,
|
|
5
|
-
email: 'john.doe@example.com',
|
|
6
|
-
};
|
|
7
|
-
const result = await jane.boundary({
|
|
8
|
-
name: jane.value(input.name).string().nonEmpty(),
|
|
9
|
-
age: jane.value(input.age).parse('numeric').positive(),
|
|
10
|
-
email: jane.value(input.email).nonEmpty().isEmail(),
|
|
11
|
-
});
|
|
12
|
-
console.dir(result, { depth: null, colors: true });
|