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

How re-rendering should be done in efficient way while data change in flux architecture controller? #4350

Closed
tsfahmad opened this issue Jul 11, 2015 · 3 comments

Comments

@tsfahmad
Copy link

I have a controller which consist of many views in it. Only my controller is having state and I pass data to my views through props. Now problem is suppose my view depends on number of product.
Say we have more than 100 products and each product consist of number of properties related to it. Now each property also have their own property on it. So if I change value of a sub-property then i have to re-render. No We dispatch the change event so it again start re-rendering from controller and it have to process through all the codes like all condition checks, loops etc which is time consuming. So how should we achieve it flux-react architecture?

@andersekdahl
Copy link

If you're concerned about performance of rerendering and diffing, you might want to look into Immutable.js and shouldComponentUpdate. It makes it possible to skip rerendering components for which the data hasn't changed.

@jimfb
Copy link
Contributor

jimfb commented Jul 11, 2015

In the future, we might be able to do something like this: #3920 or #3398 (both options still in discussion, feel free to let us know which you like better!)

@zpao
Copy link
Member

zpao commented Jul 13, 2015

I'm going to close this out since it's an architectural question. Check out other issues and consider discussing this on stack overflow or the discussion boards (discuss.reactjs.com)

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

No branches or pull requests

4 participants