UNPKG

ts-base-error

Version:
17 lines 594 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); /** * General APP Error. * @see https://github.com/Microsoft/TypeScript/wiki/Breaking-Changes#extending-built-ins-like-error-array-and-map-may-no-longer-work * @see https://stackoverflow.com/a/55066280/717267 * @see https://stackoverflow.com/a/60250733/717267 */ class BaseError extends Error { constructor(message) { const trueProto = new.target.prototype; super(message); Object.setPrototypeOf(this, trueProto); } } exports.default = BaseError; //# sourceMappingURL=index.js.map