komi-logger
Version:
High-performance, type-safe logging library for Bun with advanced TypeScript body intersection, modular strategy pattern, transform streams, and immutable API design.
19 lines (18 loc) • 511 B
TypeScript
export interface KomiErrorOptions<T = unknown> {
/**
* The error message describing what went wrong.
*/
message?: string;
/**
* A unique key identifying the type of error, useful for localization or error handling.
*/
key?: string;
/**
* The HTTP status code associated with the error, typically used in API responses.
*/
httpStatusCode?: number;
/**
* The cause of the error, which can be an original error or additional context.
*/
cause?: T;
}