Skip to content

Comments #8

@hiqsol

Description

@hiqsol

I have a specific need, can it be implemented in this library?

I want to have dumped array with comments like this:

return [
    'a' => [
        'a1' => 'one', /// from file-a
    ],
    'b' => [
        'b2' => 'two', /// from file-b
    ],    
];

It could be implemented with providing callback:

public function commentsCallback(array $keys, $value) {
    /// example, actual logic will be other
    if ($keys == ['a','a1'] and $value === 'one') return 'from file a';
    /// ....
    return null;
}

Thanks in advance!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions