Javascript icon indicating copy to clipboard operation
Javascript copied to clipboard

Feature request: debug for loops, command: watch all.

Open falafflepotatoe opened this issue 9 years ago • 2 comments

I feel you should be able to watch variables inside for loops with lighttables watch, I could not.

Maybe see comealive.io for an example.

I also think a 'watch all' cmd is lacking.

falafflepotatoe avatar Feb 03 '16 19:02 falafflepotatoe

Alive is certainly pretty cool – thanks for the link!

But without some of the UI features that Alive includes – like the slider for changing the current loop index variable value – it's not clear how this would work in LT. If you watch a variable inside a loop, you'd just see the final value of the variable. I guess we could stack all of the values for each iteration or, to be even cooler, stack any variables inside the loop being watched together (e.g. in a visual box) for each iteration.

Why not take a stab at this yourself? Myself, or the other core team members, or even some other contributors, will be happy to help answer any questions you might have.

kenny-evitt avatar Feb 05 '16 22:02 kenny-evitt

@kenny-evitt

I thought about that, while developing it my plan was to just display [val1, val2, val3] or { 0: val1, 1: val2, 2: val3 } where the key is the iteration. At least until we implemented the slider.

Thought about trying it myself but not a cljs guy. I'm hestitant to get addicted to hacking the light table src and then spend the next year writing IDEs.

falafflepotatoe avatar Feb 06 '16 10:02 falafflepotatoe