effect-errors 1.3.6 → 1.3.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/README.md +2 -2
- package/capture-errors.d.ts +2 -2
- package/capture-errors.js +2 -2
- package/package.json +8 -8
package/README.md
CHANGED
|
@@ -166,8 +166,8 @@ export interface CapturedErrors {
|
|
|
166
166
|
}
|
|
167
167
|
|
|
168
168
|
export interface CaptureErrorsOptions {
|
|
169
|
-
reverseSpans
|
|
170
|
-
stripCwd
|
|
169
|
+
reverseSpans?: boolean;
|
|
170
|
+
stripCwd?: boolean;
|
|
171
171
|
}
|
|
172
172
|
|
|
173
173
|
type captureErrorsFunction: <E>(cause: Cause<E>, options: CaptureErrorsOptions) => CapturedErrors
|
package/capture-errors.d.ts
CHANGED
|
@@ -17,7 +17,7 @@ export interface CapturedErrors {
|
|
|
17
17
|
errors: ErrorData[];
|
|
18
18
|
}
|
|
19
19
|
export interface CaptureErrorsOptions {
|
|
20
|
-
reverseSpans
|
|
21
|
-
stripCwd
|
|
20
|
+
reverseSpans?: boolean;
|
|
21
|
+
stripCwd?: boolean;
|
|
22
22
|
}
|
|
23
23
|
export declare const captureErrors: <E>(cause: Cause<E>, { reverseSpans, stripCwd }?: CaptureErrorsOptions) => CapturedErrors;
|
package/capture-errors.js
CHANGED
|
@@ -33,13 +33,13 @@ var captureErrors = function (cause, _a) {
|
|
|
33
33
|
}
|
|
34
34
|
var stack;
|
|
35
35
|
if (maybeStack !== undefined) {
|
|
36
|
-
stack = stripCwd ? (0, strip_cwd_path_1.stripCwdPath)(maybeStack) : maybeStack;
|
|
36
|
+
stack = stripCwd === true ? (0, strip_cwd_path_1.stripCwdPath)(maybeStack) : maybeStack;
|
|
37
37
|
}
|
|
38
38
|
return {
|
|
39
39
|
errorType: errorType,
|
|
40
40
|
message: message,
|
|
41
41
|
stack: stack,
|
|
42
|
-
spans: reverseSpans ? spans.toReversed() : spans,
|
|
42
|
+
spans: reverseSpans === true ? spans.toReversed() : spans,
|
|
43
43
|
isPlainString: isPlainString,
|
|
44
44
|
};
|
|
45
45
|
});
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"repository": "https://github.com/jpb06/effect-errors.git",
|
|
3
3
|
"main": "index.js",
|
|
4
4
|
"name": "effect-errors",
|
|
5
|
-
"version": "1.3.
|
|
5
|
+
"version": "1.3.8",
|
|
6
6
|
"author": "jpb06 <jp.bois.06@outlook.fr>",
|
|
7
7
|
"description": "A POC for errors reporting in Effect",
|
|
8
8
|
"keywords": [],
|
|
@@ -27,21 +27,21 @@
|
|
|
27
27
|
"run-examples": "bun run ./src/examples/util/run-all"
|
|
28
28
|
},
|
|
29
29
|
"dependencies": {
|
|
30
|
-
"@effect/schema": "^0.66.
|
|
30
|
+
"@effect/schema": "^0.66.12",
|
|
31
31
|
"chalk": "<5",
|
|
32
|
-
"effect": "^3.0
|
|
32
|
+
"effect": "^3.1.0"
|
|
33
33
|
},
|
|
34
34
|
"devDependencies": {
|
|
35
35
|
"@eslint/eslintrc": "^3.0.2",
|
|
36
36
|
"@eslint/js": "^9.1.1",
|
|
37
|
-
"@stylistic/eslint-plugin": "^1.
|
|
38
|
-
"@stylistic/eslint-plugin-ts": "^1.
|
|
37
|
+
"@stylistic/eslint-plugin": "^1.8.0",
|
|
38
|
+
"@stylistic/eslint-plugin-ts": "^1.8.0",
|
|
39
39
|
"@types/eslint": "^8.56.10",
|
|
40
40
|
"@types/fs-extra": "^11.0.4",
|
|
41
41
|
"@types/node": "^20.12.7",
|
|
42
42
|
"@typescript-eslint/eslint-plugin": "^7.8.0",
|
|
43
43
|
"@typescript-eslint/parser": "^7.8.0",
|
|
44
|
-
"@vitest/coverage-v8": "^1.5.
|
|
44
|
+
"@vitest/coverage-v8": "^1.5.3",
|
|
45
45
|
"copyfiles": "^2.4.1",
|
|
46
46
|
"del-cli": "^5.1.0",
|
|
47
47
|
"eslint": "^9.1.1",
|
|
@@ -50,7 +50,7 @@
|
|
|
50
50
|
"eslint-import-resolver-typescript": "^3.6.1",
|
|
51
51
|
"eslint-plugin-import": "^2.29.1",
|
|
52
52
|
"eslint-plugin-markdown": "^4.0.1",
|
|
53
|
-
"eslint-plugin-n": "^17.
|
|
53
|
+
"eslint-plugin-n": "^17.4.0",
|
|
54
54
|
"eslint-plugin-prettier": "^5.1.3",
|
|
55
55
|
"eslint-plugin-promise": "^6.1.1",
|
|
56
56
|
"eslint-plugin-vitest": "^0.5.4",
|
|
@@ -60,7 +60,7 @@
|
|
|
60
60
|
"readme-package-icons": "^1.1.14",
|
|
61
61
|
"typescript": "*",
|
|
62
62
|
"typescript-eslint": "^7.8.0",
|
|
63
|
-
"vitest": "^1.5.
|
|
63
|
+
"vitest": "^1.5.3",
|
|
64
64
|
"vitest-mock-extended": "^1.3.1"
|
|
65
65
|
}
|
|
66
66
|
}
|