-
-
Notifications
You must be signed in to change notification settings - Fork 2k
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
stop adding null string key when there is a ref #1254
Conversation
is there anything else needed before this is looked at? It'd be great to get it merged. Idk how many people it's affecting but I know my project can't upgrade to react 16 until it's done. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This LGTM - it needs a rebase on the CLI to remove the merge commit, and it'll need a few more reviews.
cool thanks. i rebased off of master |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
3a5e564
to
bdccbd8
Compare
I rebased this. Does it need more approvals? |
Yes, I'd like a couple more reviewers to take a look first. |
Hi @ljharb is there anything i can do to get this reviewed and merged? I know it's blocking me from updating to react 16, and I'm sure it's blocking others as well. |
I'll give it a try locally. |
any luck with this? It's getting hard to keep it up to date because merge conflicts keep happening as master updates. |
Still working on it :-) I'll keep it up to date for you tho! |
thanks! |
- [fix] stop adding null string key when there is a ref (enzymejs#1254)
I believe #1511 was introduced in this PR |
- [fix] stop adding null string key when there is a ref (enzymejs#1254)
This fixes #1240 . Since react turns all valid (aka not undefined) keys into strings in react.createElement, it made sense to just remove falsey keys from nodes, so that when they were passed back through createElement, they didn't get turned into strings.
The tests I added fail with errors like
AssertionError: expected 'null' to equal null
without the changes I made.