Skip to content
This repository has been archived by the owner on Dec 22, 2023. It is now read-only.

Fix key warning #10

Merged
merged 3 commits into from
Jan 19, 2016
Merged

Fix key warning #10

merged 3 commits into from
Jan 19, 2016

Conversation

lithin
Copy link
Contributor

@lithin lithin commented Jan 14, 2016

Addressing issue #7 - adds a unique key to every node that is parsed.

@@ -47,6 +49,8 @@ var ProcessNodeDefinitions = function(React) {
});
}

elementProps.key = ++index;
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @lithin, since the key property is always set, do you mind moving this up to where elementProps is defined? So that it will look like this:

var elementProps = {
    key: ++index
};

Thanks,

Mike

@lithin
Copy link
Contributor Author

lithin commented Jan 18, 2016

@mikenikles Thanks for the comment! Do you know why the tests are failing?

@mikenikles
Copy link
Owner

Yeah @lithin it was due to a newer version of blanket. If you merge the latest master into your branch, it should fix it. More info via #12

@lithin
Copy link
Contributor Author

lithin commented Jan 19, 2016

@mikenikles Could you please merge this PR if you're happy with it?

@mikenikles
Copy link
Owner

Sure thing, thanks a lot for your contribution @lithin! I will release it to npm tonight (in about 10 hours from now)

mikenikles pushed a commit that referenced this pull request Jan 19, 2016
@mikenikles mikenikles merged commit a4996ca into mikenikles:master Jan 19, 2016
@mikenikles
Copy link
Owner

@lithin version 0.1.2 is available in npm. Please let me know if you run into any problems.

@lithin
Copy link
Contributor Author

lithin commented Jan 20, 2016

@mikenikles Thank you!

@benjeffery
Copy link
Contributor

Hi,
I just opened #28 which I think solves this issue in a way that lets components persist where possible.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants