扫码关注官方订阅号
比如在代码里写console.log("test");在控制台会显示2017/1/29 21:36:00:00.0 test
console.log("test");
2017/1/29 21:36:00:00.0 test
是哪里可以配置?
认证0级讲师
console.log(date()+"test");
console.log(new Date()+"test");
function log(str){ console.log(new Date().toLocaleString() + str) } log('log string')
{ var newLog = function(){ console.info(new Date().toLocaleString()); arguments.callee.oldLog.apply(this, arguments); }; newLog.oldLog= console.log, console.log = newLog; } console.log("test function", new Array("Saab","Volvo","BMW")); console.log("test function again", new RegExp("e"), 23333);
微信扫码关注PHP中文网服务号
QQ扫码加入技术交流群
Copyright 2014-2026 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号
PHP学习
技术支持
返回顶部
console.log(new Date()+"test");