我在我的代码中使用console.log(),其中输出正在打印 [英] i am using console.log() in my code.where the output is printing
问题描述
我正在我的代码中使用console.log().输出正在打印
i am using console.log() in my code.where the output is printing
推荐答案
如果您使用Firebug之类的工具来检查您的代码.假设您这样做:
You can view any messages logged to the console if you use a tool such as Firebug to inspect your code. Let''s say you do this:
console.log('Testing console');
当您在Firebug(或决定使用哪种工具检查代码)中访问控制台时,您将看到告诉该功能进行记录的任何消息.当您想查看函数是否正在执行,或者变量是否正在正确传递/分配时,此功能特别有用.实际上,这对于弄清代码出了什么问题非常有价值.
发件人: http://stackoverflow.com/Questions/4743730/javascript-what-is-console-log-and-how-do-i-use-it [
When you access the console in Firebug (or whichever tool you decide to use to inspect your code), you will see whatever message you told the function to log. This is particularly useful when you want to see if a function is executing, or if a variable is being passed/assigned properly. It''s actually rather valuable for figuring out just what went wrong with your code.
FROM : http://stackoverflow.com/questions/4743730/javascript-what-is-console-log-and-how-do-i-use-it[^]
这篇关于我在我的代码中使用console.log(),其中输出正在打印的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!