The 100ms pause between steps is what makes the log readable while it
fills, but it also means the fibonacci example takes 210 of them, three
and a half minutes of watching, to answer 8. Run instantly skips the
pause. The checkbox is read per step, so ticking it part way through a
long run takes effect immediately.
A run with nothing to watch does not want its trace spelled out either, so
afterwards everything between the program and what it ended on goes into a
details element labelled with the number of steps. The whole run happens
in one task, so the rows never paint before being folded.
The first and last rows stay out of the fold: it keeps the log reading as
program, what happened, result - and resetLog builds each history entry's
summary from log.firstChild.lastChild, so a fold in first position would
collapse every past run under a summary holding its entire trace. Folding
happens in a finally, so a program that throws keeps its steps tidy too,
with the error left visible below them.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
- author
- Marijn Besseling <njirambem@gmail.com>
· 2026-09-12 19:37 UTC
- commit
- a273ce43a6e60b176db02c755322738a916f179d
- parent
- 7afeca15f1
- tree
- browse at this commit