Skip to content
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

Potential performance issues? #1

Open
markerikson opened this issue Apr 25, 2016 · 0 comments
Open

Potential performance issues? #1

markerikson opened this issue Apr 25, 2016 · 0 comments

Comments

@markerikson
Copy link

At first glance, this seems like it would be bad for performance on several levels. The constant calls to .toJS() are potentially expensive; part of the reason to use Immutable.js in the first place is to enable fast shouldComponentUpdate implementations via shallow equality, and Immutable references make that easier; and the constant .toJS() calls as far as I know mean you're returning a new object every time anyway.

As I understand it, generally to get the best performance you would want to keep things in Immutable form all the way down to your render function.

Also, there's a bunch of existing Immutable.js<->Redux interop libs already, most of which are listed over at the Immutable Data page in my Redux addons catalog.

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

No branches or pull requests

1 participant