Skip to content

Print stack trace for errors #59

@danielb2

Description

@danielb2
> try { JSON.parse("") } catch (e) { console.log(e); }
SyntaxError: Unexpected end of JSON input
    at Object.parse (native)
    at repl:1:12
    at sigintHandlersWrap (vm.js:22:35)
    at sigintHandlersWrap (vm.js:73:12)
    at ContextifyScript.Script.runInThisContext (vm.js:21:12)
    at REPLServer.defaultEval (repl.js:340:29)
    at bound (domain.js:280:14)
    at REPLServer.runBound [as eval] (domain.js:293:12)
    at REPLServer.<anonymous> (repl.js:539:10)
    at emitOne (events.js:96:13)
undefined
> p = require('purdy')
{ [Function] stringify: [Function] }
[Atry { JSON.parse("") } catch (e) { p(e); }
[SyntaxError: Unexpected end of JSON input]

Purdy is too sparse here

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions