You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, when using the dump() function to output multiple variables, it's not immediately clear which dump corresponds to which variable if no labels are provided. This can be particularly confusing when debugging complex data structures or when multiple dumps are present on the same page.
Feature Request:
Enhance the frontend UI to display variable labels from the var-dumper context, making it easier to identify the relationship between the dumps and the variables.
Consider the scenario where two variables are dumped without explicit labels:
dump($foo, $bar);
In the current setup, $foo and $bar would be assigned default numeric labels such as 1 and 2. The corresponding JSON payload might look like this:
{
"uuid": "018ff255-37b1-7146-a984-53528d523f70",
"project": null,
"type": "var-dump",
"payload": {
"context": {...},
"payload": {
"label": "2",
"type": "string",
"value": "Here is a random phrase"
}
},
"timestamp": 1717757622.194
}
However, if named labels are used:
dump(label1: $foo, label2: $bar);
The JSON payload should reflect these labels, aiding in clearer debugging:
{
"uuid": "018ff255-37b1-7146-a984-53528d523f70",
"project": null,
"type": "var-dump",
"payload": {
"context": {...},
"payload": {
"label": "label2",
"type": "string",
"value": "Here is a random phrase"
}
},
"timestamp": 1717757622.194
}
It would be great to put a label in a dump event
Benefits:
Improves clarity and traceability of variable dumps.
The text was updated successfully, but these errors were encountered:
Currently, when using the
dump()
function to output multiple variables, it's not immediately clear which dump corresponds to which variable if no labels are provided. This can be particularly confusing when debugging complex data structures or when multiple dumps are present on the same page.Feature Request:
Enhance the frontend UI to display variable labels from the
var-dumper
context, making it easier to identify the relationship between the dumps and the variables.Consider the scenario where two variables are dumped without explicit labels:
In the current setup,
$foo
and$bar
would be assigned default numeric labels such as1
and2
. The corresponding JSON payload might look like this:However, if named labels are used:
The JSON payload should reflect these labels, aiding in clearer debugging:
It would be great to put a label in a dump event
Benefits:
Improves clarity and traceability of variable dumps.
The text was updated successfully, but these errors were encountered: