Skip to content

Using React.Children.map in getChildMapping is causing element keys to change. #912

@maitrungdong

Description

@maitrungdong

What is the current behavior?

When I compare keys in child elements then get an issue that these keys has an additional prefix .$.
I think that is an unpredictable behavior and can make some bugs!!!

What is the expected behavior?

I want to these keys should be persisted.

Could you provide a CodeSandbox demo reproducing the bug?

I found this issue in the code base. The reason is using Children.map in getChildMapping method.
A similar issue on stackoverflow: link

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions