You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, errors are logged to the console using console.error. However, it would be useful to provide your own callback for the message, which would allow for using tracing::error instead, which would also enable panics to show in wasm-pack test --node, as well as making it possible for providing your own error screens
Proposed Solution
Provide a new setup function which takes a closure to invoke with the error message, and make the existing set_once use this internally by falling back to console.error
Making a custom panic hook in place which will contain almost all of this crate's logic, as I have currently done to enable this to work with wasm-pack test and non console environments
The text was updated successfully, but these errors were encountered:
Motivation
Currently, errors are logged to the console using
console.error
. However, it would be useful to provide your own callback for the message, which would allow for usingtracing::error
instead, which would also enable panics to show inwasm-pack test --node
, as well as making it possible for providing your own error screensProposed Solution
Provide a new setup function which takes a closure to invoke with the error message, and make the existing
set_once
use this internally by falling back toconsole.error
Alternatives
Making a custom panic hook in place which will contain almost all of this crate's logic, as I have currently done to enable this to work with
wasm-pack test
and non console environmentsThe text was updated successfully, but these errors were encountered: