首页 > 代码库 > javascript 调试技巧

javascript 调试技巧

  • 不用alert,用console.log()
<!DOCTYPE html> <html> <head> <script type="text/javascript"> function showLog(message){     console.log(message); } function test(name){     showLog(name); } test("hello"); </script> </head>         <body> </body> </html>

javascript 调试技巧