(value: unknown, context: FrontendErrorContext)
| 83 | }; |
| 84 | |
| 85 | const errorFromValue = (value: unknown, context: FrontendErrorContext): Error => { |
| 86 | // oxlint-disable-next-line executor/no-error-constructor -- boundary: a crash-reporting transport only understands built-in Errors; this module is the adapter that produces them |
| 87 | const error = new Error(describeUnknown(value, context)); |
| 88 | error.name = nameFromUnknown(value, context.surface); |
| 89 | return withOriginalCause(error, value); |
| 90 | }; |
| 91 | |
| 92 | const errorFromCause = (cause: Cause.Cause<unknown>, context: FrontendErrorContext): Error => { |
| 93 | // `prettyErrors` is the non-lossy conversion: it renders every reason — |
no test coverage detected