Everytime I'll add a setState on the function for the onTableChange, it will show this error:
Maximum update depth exceeded. This can happen when a component repeatedly calls setState inside componentWillUpdate or componentDidUpdate. React limits the number of nested updates to prevent infinite loops.
I wanted to get the thetableState.displayData hence, I added this, however, this will result to an error that says:
Maximum update depth exceeded. This can happen when a component repeatedly calls setState inside componentWillUpdate or componentDidUpdate. React limits the number of nested updates to prevent infinite loops.
Everytime I'll add a
setState
on the function for theonTableChange
, it will show this error:Maximum update depth exceeded. This can happen when a component repeatedly calls setState inside componentWillUpdate or componentDidUpdate. React limits the number of nested updates to prevent infinite loops.
Expected Behavior
Based on the official example, this is how they do it: https://codesandbox.io/s/trusting-jackson-k6t7ot?file=/examples/on-table-init/index.js
Current Behavior
I wanted to get the the
tableState.displayData
hence, I added this, however, this will result to an error that says:Maximum update depth exceeded. This can happen when a component repeatedly calls setState inside componentWillUpdate or componentDidUpdate. React limits the number of nested updates to prevent infinite loops.
Steps to Reproduce (for bugs)
Your Environment