@foal/core
Version:
Full-featured Node.js framework, with no complexity
14 lines (13 loc) • 566 B
TypeScript
import { Context, HttpResponseInternalServerError } from '../http';
/**
* Renders the default HTML page when an error is thrown or rejected in the application.
*
* The page is different depending on if the configuration key `settings.debug` is
* true or false.
*
* @export
* @param {Error} error - The error thrown or rejected.
* @param {Context} ctx - The Context object.
* @returns {Promise<HttpResponseInternalServerError>} The HTTP response.
*/
export declare function renderError(error: Error, ctx: Context): Promise<HttpResponseInternalServerError>;