node.js - How to Debug a JavaScript code when it is loaded by document.write? -
i can see code in element view in chrome, not in source because load document.write
function.
how set breakpoint in case?
i suppose have access source code generates document.write, can add call 'debugger' this:
<script> document.write('<sc' + 'ript> debugger; alert(0);</s' + 'cript>'); </script>
i have debugger opened on chrome, stop execution , show generated code on sources tab.
Comments
Post a Comment