10000 [Var-Dumper] Automatically add an hyperlink to the file in CliDumper · Issue #30830 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content
[Var-Dumper] Automatically add an hyperlink to the file in CliDumper #30830
Closed
@ktherage

Description

@ktherage

Description
During few days, i had to use the dump() function in order to debug failing unit test.
In order to see where i placed dumps (and don't forget to remove them after the 6291 fix) i used to add the following argument to my dumps dump(__FILE__.' l.'.__LINE__, $myVar).

** Possible solution **
I made a POC which uses the debug_backtrace to get file and line and add those attributes to style which has effect to add a href in the console to the file. Ideally the final version would add a line like using dump(__FILE__.' l.'.__LINE__, $myVar) with this href.

Example
master...ktherage:poc-var-dump

Gif preview of the POC
poc-var-dump

WDYT ?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0