-
Notifications
You must be signed in to change notification settings - Fork 231
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
Performance when receiving same props #124
Comments
Do a performance test with option 1 and see if that resolves your issue. If On Tuesday, September 1, 2015, Thomas Shafer notifications@github.com
|
This is what I've got so far: amplii@4bd61dd |
Issues resolved in #125. |
Hey @fmoo,
There's a significant performance issue. I have a parent component to the tokenizer which re-renders frequently. In my situation, it is improbable to change this parent component to update less frequently. My re-render is extremely fast and usually doesn't update the dom. I've tested it when I re-render my component every keydown and there is no performance slowdown with the tokenizer removed (separate input field). I believe the issue is that every time I pass the same props to the tokenizer, it calls a fuzzy match on all of my options. It happens because of this line: https://github.com/fmoo/react-typeahead/blob/master/src/typeahead/index.js#L283:L287 .
Some possible solutions:
Thanks!
The text was updated successfully, but these errors were encountered: