dillon1000/react
Commit
Browse files Make findComponentRoot faster with more nodeCache
This is an alternative, less-invasive, fix for #891. Test Plan: On http://jsbin.com/OqOJidIQ/2/edit, got timings like [75, 56, 30, 36, 27, 27, 28, 32, 27, 27, 28, 31] instead of the old [75, 729, 46, 32, 28, 34, 26, 27, 27, 30, 26, 26]. I also added a counter to getID and saw it was called 3014 times instead of the old 636264. (3014 is the number of nodes (3000) plus 3 calls that happen for the initial render and 1 for each of the 11 renders after that.)
Changed paths2 files
First-parent comparisonsrc/core/ReactInstanceHandles.js ModifiedM src/core/ReactMount.js ModifiedPatch
Files changed
Rendering syntax-highlighted changes…