UNPKG

@gotamedia/utils

Version:

Set of Utils helper for NodeJs Runtime.

10 lines (9 loc) 403 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.getErrorTrace = void 0; var getErrorTrace = function (error) { var _a; var errorObject = error || new Error(); return (_a = errorObject.stack) === null || _a === void 0 ? void 0 : _a.split("\n").map(function (str) { return str.trim(); }).filter(Boolean).slice(1); }; exports.getErrorTrace = getErrorTrace;