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, all error types seem to be represented as new Error(<message>). Other error types like SyntaxError, ReferenceError etc, are not serialized any differently
Suggestion:
stringify(newSyntaxError('syntax'));// "new SyntaxError(syntax')"stringify(newReferenceError('syntax'));// "new ReferenceError(syntax')"
...
It should be possible to do this using Error.prototype.name with the caveat that it can be overridden to an empty string, which should probably be handled
Activity