Replicating airbnb following the atomic design principles...
Home > @nextbnb/common > BaseError
Blueprint for the BaseError which will be extended by other specific errors
Signature:
export declare class BaseError extends Error
Extends: Error
const error = new BaseError({ message: 'There is a base error!', statusCode: 400 })
error.get()
Constructor | Modifiers | Description |
---|---|---|
(constructor)({ message, statusCode }) | Constructs a new instance of the BaseError class |
Property | Modifiers | Type | Description |
---|---|---|---|
message | string | ||
status | string | ||
statusCode | THttpStatus |
Method | Modifiers | Description |
---|---|---|
get() |