How to use stack-trace

Comprehensive stack-trace code examples:

How to use stack-trace.get:

99
100
101
102
103
104
105
106
107
108
if(!this.rootPath){
    console.log('ATENCIÓN hay que poner be.rootPath antes de llamar a super()');
    this.rootPath=Path.resolve(__dirname,'..');
}
console.log('rootPath',this.rootPath);
var trace = stackTrace.get();
trace.forEach(function(callSite){
    var path = callSite.getFileName();
    if(path && !path.startsWith('internal/') && !path.startsWith('node:internal/')){
        path = Path.dirname(path);

How to use stack-trace.parse:

162
163
164
165
166
167
168
169
170
171
   */

}, {
  key: "getTrace",
  value: function getTrace(err) {
    var trace = err ? stackTrace.parse(err) : stackTrace.get();
    return trace.map(function (site) {
      return {
        column: site.getColumnNumber(),
        file: site.getFileName(),