当我使用Xdebug在VSCODE中调试变量时,在鼠标越过的预览或检查面板中将长变量(例如SQL句子(截断。
。我如何看完整的文本?
i有相同的问题(隐藏的儿童变量,只有32个内部变量不可见(。
更新您的启动配置(.vscode/launch.json
(。设置xdebugSettings
:
"xdebugSettings": {
"max_children": 999, // max number of array or object children to initially retrieve.
"max_depth": 10, // maximum depth that the debugger engine may return when sending arrays, hashs or object structures to the IDE.
"max_data": 10240 // max length of a string value of an inspected variable. The default value is 1024. So some values can be clipped.
}
{
"version": "0.2.0",
"configurations": [
{
"name": "Listen for Xdebug",
"type": "php",
"request": "launch",
"port": 9000,
"pathMappings": {
"/app": "${workspaceFolder}"
},
"xdebugSettings": {
"max_children": 999,
"max_depth": 10,
"max_data": 10240
}
},
]}
查看所有参数:https://github.com/xdebug/vscode-php-debug#supported-launchjson-settings
有show_hidden
和max_data
。
有时在设置中太大的值或没有有限的值可以对系统减速,然后将停止调试。