I have a script which I want to allow users to debug right in the browser. I can get line numbers for the breakpoints and I can get local variable values what I'm curious about is how do I pause the actual script execution at a specific line? I tried putting hidden sleep() calls along with the local vars dumping code, wonder if there's more elegant solution for the problem?
Just a clarification - the console isn't available to me. I can only use regular JS script features. I use chrome dev tools for years but never experienced the need for emulating debugger;
instruction by JS code before.