node icon indicating copy to clipboard operation
node copied to clipboard

lib: add util.getCallSite() API

Open RafaelGSS opened this issue 6 months ago • 17 comments

This pull request introduces a new API method, util.getCallSite(), which provides a way to capture and inspect the call stack within a Node.js application. The method returns an array of CallSite objects, so developers can retrieve information about each function call in the stack trace.

Previously, they could reach the same behaviour by using Error.prepareStackTrace but, this API isn't that friendly IMO.

RafaelGSS avatar Aug 14 '24 17:08 RafaelGSS