-
Notifications
You must be signed in to change notification settings - Fork 81
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Children's key is missing #301
Comments
Hello @yoyoyooo, did you have a more complete example to show us? I just check our test suite, we have use case with some react-element-to-jsx-string/src/index.spec.js Lines 713 to 718 in 768cce0
|
I think this test case is not suitable to my problem because there is only one div. My problem is if both child and parent have its Input
Output
The inner div's |
Looks like this issue is still happening in version 15.0.0: Input: import React from "https://esm.sh/[email protected]";
import reactElementToJsxString from "https://esm.sh/[email protected]";
console.log(reactElementToJsxString(
<div aprop="test" key="yes">
<div aprop="test" key="yes" />
</div>
)); Output:
To reproduce: https://codepen.io/danielhara/pen/GReQOPX?editors=1111 |
@armandabric , @yoyoyooo , I've created this PR to fix this bug: #841 🚀 |
Issue: There is something wrong with children's key.
Example: The expected output should be
But I got an output without
RadioButton's
key:I am sure the radio button element is correct:
Any suggestions about this?
The text was updated successfully, but these errors were encountered: