Friday, January 25, 2008

Web Debugging

The topic of web debugging in Run BASIC came up today in the forums, and the topic started with some ambitious ideas from Bill W. who always has something interesting to say (here for example).

Run BASIC does need a debugging facility. I realize that most web programmers probably write to logs, and you can do that in RB without adding anything but we can make it a lot easier. Just for starters I was thinking of adding a logging object of some kind. A debug button would be added to the toolbar, and then you could specify either logging of all variable changes, or specify watches so that only certain variables would get logged, and a LOG statement could also be added that would only log if the program is executed in debug mode (instead of merely run).

Also, it would be no hard matter to include an inspector object which could be rendered into the page whereever it is convenient for the programmer. You could examine and change the value of variables, and perhaps even execute code dynamically on a running program in the web browser.

I'm eager for feedback on this!