Hacker News new | past | comments | ask | show | jobs | submit login

Time-travel debugging is miles better than the old way of placing breakpoints. For me, debugging with breakpoints was always a pain. I often skipped through stuff accidentally and had to start all over again from the beginning, or accidentally went inside some third-party library code that I did not intend to, or placed the breakpoint at the wrong spot. It was just slow and inconvenient, unlike React DevTools where you can see every change and step forward or backward, replay events and observe the state at various points without having to put watchers on every variable / expression.



Time travel debugging is Redux devtools, not React devtools.


Oh, you're right. Been working with Vue lately where the component and Vuex inspectors are packaged into one devtools, that's why I got confused.


You can return back to the previous statements in any decent debugger instead of starting from scratch. And by default they don’t go inside third party libraries unless you specify that it’s what you want. What kind of debuggers were you using?


> You can return back to the previous statements in any decent debugger

That's a bit of a stretch. What debuggers are /you/ using?


Visual studio, rider, IntelliJ idea, eclipse, they can all do it, although the last two can only go to the last stack call instead of moving to the specific statement if I recall correctly.


IntelliJ cannot step back to the previous statement as the JVM does not support this. Thus neither can Eclipse.


It can discard the last stack frame, as I said in my edited comment.


You can move around the execution in the VS debugger - if you’re at a break point you can move execution earlier in that function etc. That’s the only debugger I’ve seen doing that though.


You can also use the “restart stack frame” option in Chrome DevTools to move back to the beginning of any function currently being executed. So if you skip past something on accident, you can just restart the closest stack frame to bring you back.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: