stacktracejs/stacktrace.js

Way to convert StackFrames back into a traditional Error stack

robross0606 opened this issue · 0 comments

The API provides a way to parses an Error.stack into an array of StackFrame. However, as far as I can tell, it does not provide a way to convert an array of StackFrame back into a simple Error.stack.

Expected Behavior

The API should be able to convert either direction between an array of StackFrame and Error.stack.

Current Behavior

The API can only convert Error.stack into an array of StackFrame.

Context

There are times you need to generate an array of StackFrame and then push that into a regular Error object for usage downstream by code that does not know how to handle StackFrame objects.