yedra 0.14.0 → 0.14.1
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/routing/env.d.ts +2 -1
- package/dist/routing/env.js +3 -2
- package/package.json +4 -4
package/dist/routing/env.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
1
|
import type { Typeof } from '../validation/body.js';
|
|
2
|
+
import { type ObjectSchema } from '../validation/object.js';
|
|
2
3
|
import type { Schema } from '../validation/schema.js';
|
|
3
|
-
export declare const parseEnv: <T extends Schema<unknown
|
|
4
|
+
export declare const parseEnv: <T extends Record<string, Schema<unknown>>>(shape: T) => Typeof<ObjectSchema<T>>;
|
package/dist/routing/env.js
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { ValidationError } from '../validation/error.js';
|
|
2
|
-
|
|
2
|
+
import { laxObject } from '../validation/object.js';
|
|
3
|
+
export const parseEnv = (shape) => {
|
|
3
4
|
try {
|
|
4
|
-
return
|
|
5
|
+
return laxObject(shape).parse(process.env);
|
|
5
6
|
}
|
|
6
7
|
catch (error) {
|
|
7
8
|
if (error instanceof ValidationError) {
|
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "yedra",
|
|
3
|
-
"version": "0.14.
|
|
3
|
+
"version": "0.14.1",
|
|
4
4
|
"repository": "github:0codekit/yedra",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"devDependencies": {
|
|
7
7
|
"@biomejs/biome": "^1.9.4",
|
|
8
|
-
"@types/bun": "^1.2.
|
|
9
|
-
"@types/node": "^22.
|
|
8
|
+
"@types/bun": "^1.2.12",
|
|
9
|
+
"@types/node": "^22.15.17",
|
|
10
10
|
"@types/uuid": "^10.0.0",
|
|
11
11
|
"@types/ws": "^8.18.1",
|
|
12
12
|
"typescript": "^5.8.3"
|
|
@@ -25,6 +25,6 @@
|
|
|
25
25
|
"dependencies": {
|
|
26
26
|
"mime": "^4.0.7",
|
|
27
27
|
"uuid": "^11.1.0",
|
|
28
|
-
"ws": "^8.18.
|
|
28
|
+
"ws": "^8.18.2"
|
|
29
29
|
}
|
|
30
30
|
}
|