书 - 雄辩的JavaScript代码问题 [英] book - eloquent javascript code problem

查看:53
本文介绍了书 - 雄辩的JavaScript代码问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在读这本书雄辩的javascript



http:// eloquentjavascript。 net / 02_program_structure.html [ ^ ]



它一次又一次地使用console.log。现在,其中一位成员说console.log不能正常工作。那么,为什么本书的作者在所有示例代码中都提到了console.log。我在这里遗漏了什么吗?



因为,现在,即使从eloquent javascript书中复制粘贴代码也是如此。浏览器内没有显示任何内容。



提前致谢

I am reading this book eloquent javascript

http://eloquentjavascript.net/02_program_structure.html[^]

It uses console.log again and again. Now, one of the member here said console.log doesnt work as it is. So, why writer of this book has mentioned console.log in all the sample codes. Am i missing something here?

Because, right now, even if copy paste code from eloquent javascript book. Nothing get displayed inside browser.

Thanks in advance

推荐答案

参见 http://www.w3schools.com/js/js_output.asp [ ^ ]



它将它写入浏览器的控制台。这意味着您必须打开Chrome或FireFox或InternetExplorer的控制台窗口,无论您使用哪种浏览器。然后你可以看到输出。但它不在页面上,即document.write()。
See http://www.w3schools.com/js/js_output.asp[^]

It writes it into the browser's console. Meaning you'll have to open the console window for Chrome or for FireFox or for InternetExplorer, whichever browser you're using. Then you can see the output. But it won't be on the page, that is document.write().


这篇关于书 - 雄辩的JavaScript代码问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆