react-runner icon indicating copy to clipboard operation
react-runner copied to clipboard

Error handling with a callback to get a stacktrace

Open astahmer opened this issue 2 years ago • 0 comments

Hey, great lib !

Using the <LiveXXX> components, I'd like to have a callback to log the error so that it doesn't get completely swallowed. It would help to debug some situations, especially if there was a stack trace.

From a quick glance at the code base, it could be done somewhere in there:

https://github.com/nihgwu/react-runner/blob/974ebc932db7b7c7d59f1b50a79aed705efbf75a/packages/react-runner/src/useRunner.ts#L28-L29

what do you think ?

astahmer avatar Jun 30 '23 12:06 astahmer