redux-devtools-chart-monitor icon indicating copy to clipboard operation
redux-devtools-chart-monitor copied to clipboard

Too many options causes extreme lag

Open zekedroid opened this issue 9 years ago • 3 comments
trafficstars

Is there a way to set an initial "expandedNodes" prop to false so that it won't try and render the entire state tree? We sometimes load large json structures that we don't care to look at yet the monitor will try and render, causing it to slow down to a crawl and making the tool unusable :(

zekedroid avatar Apr 25 '16 19:04 zekedroid

I think the typical way to do what you're asking is passing a selector function to filter only the part of state you care about. From the options table.

image

For example, if you wanted to only show user data and errors from your state and exclude your api data you should be able to do something like:

<ChartMonitor select={ ({ api, user, errors }) => ({ user, errors }) } />

cchamberlain avatar Apr 26 '16 23:04 cchamberlain

Perfect :D thanks

zekedroid avatar Apr 27 '16 00:04 zekedroid

NP! :v:

cchamberlain avatar Apr 27 '16 07:04 cchamberlain