sta*_*tic 35 javascript console formatting google-chrome google-chrome-devtools
我想在Chrome控制台中打印一个数组(uniqueNames):
> console.log(uniqueNames)
Run Code Online (Sandbox Code Playgroud)
但我遇到的问题是之后
> ["Theodor", "Albertus", /* 95 other elements */ "Andreas", "Bernd", "Roland"…] <--- dots here
Run Code Online (Sandbox Code Playgroud)

如何像前100个元素一样打印完整的数组?我想复制它并在另一个应用程序中使用.或者也许可以将此数组从Chrome控制台写入文件(也在一行中,而不是整个日志)?
fad*_*ire 52
要在控制台中打印完整数组,您可以执行以下操作:
console.log(JSON.stringify(uniqueNames))