Skip to content
Meeko
Type to search the guides and the API reference. Open it from any page with / or Ctrl K; move with the arrow keys and open a result with Enter.
Get started

Contents

On this page

Not translated yet

This page has not been translated into English yet, so it is shown in Spanish.

ServerErrorInfo

interfaz Since 1.3.0

Qué fallo del proceso recibe un ServerErrorObserver como tercer argumento: una promesa rechazada sin manejar o una excepción no capturada, fuera del flujo de una petición. Los fallos de las peticiones no lo llevan.

ts
import type { ServerErrorInfo } from "@meekojs/meeko/server";

Source code src/server/errors.ts:218

Declaración #

ts
interface ServerErrorInfo {
	readonly kind: 'unhandledRejection' | 'uncaughtException'
	readonly inRequest: boolean
}

Example #

ts
import type { ServerErrorInfo } from "@meekojs/meeko/server";

function describe(info: ServerErrorInfo | undefined): string {
  if (!info) return "petición";
  return `${info.kind}${info.inRequest ? " durante una petición" : ""}`;
}

Propiedades #

kind #

propiedad sólo lectura

readonly kind: 'unhandledRejection' | 'uncaughtException'

"unhandledRejection": una promesa rechazada sin manejar; "uncaughtException": una excepción no capturada.

inRequest #

propiedad sólo lectura

readonly inRequest: boolean

true si el fallo se produjo dentro del trabajo asíncrono de una petición y requestId es el de esa petición; false si el ID es nuevo. Depende de que el runtime conserve el contexto asíncrono hasta el evento (véase la documentación de errores).

Was this page helpful?

Add a comment

It is sent when you choose “Yes” or “No”. Only the page, your answer and the comment are stored: no cookies and no personal data.

0 of 2000 characters

Edit on GitHub: packages/meeko/src/server/errors.ts