Uncaught (in promise) TypeError: Cannot read property 'columns' of undefined
at methods.js:74
at Array.forEach (
at ReactTable.getDataModel (methods.js:73)
at ReactTable.componentWillMount (lifecycle.js:28)
at vendor.js:39404
at measureLifeCyclePerf (vendor.js:39132)
at ReactCompositeComponentWrapper.performInitialMount (vendor.js:39403)
at ReactCompositeComponentWrapper.mountComponent (vendor.js:39314)
at Object.mountComponent (vendor.js:14969)
at ReactDOMComponent.mountChildren (vendor.js:43793)
3vendor.js:14986 Uncaught (in promise) TypeError: Cannot read property 'getHostNode' of null
at Object.getHostNode (vendor.js:14986)
at ReactCompositeComponentWrapper.getHostNode (vendor.js:39440)
at Object.getHostNode (vendor.js:14986)
at Object.updateChildren (vendor.js:38978)
at ReactDOMComponent._reconcilerUpdateChildren (vendor.js:43763)
at ReactDOMComponent._updateChildren (vendor.js:43867)
at ReactDOMComponent.updateChildren (vendor.js:43854)
at ReactDOMComponent._updateDOMChildren (vendor.js:41020)
at ReactDOMComponent.updateComponent (vendor.js:40838)
at ReactDOMComponent.receiveComponent (vendor.js:40800)
version: ^6.5.3
This Error appeared suddenly, without any changes in my code
Would you be able to post the relevant code? I think I am having similar problems. The first row seems to have an undefined index. I've put in some checks to prevent crashes on an undefined column index in my example.
I've kind of worked the editable rows into the pivoting table with aggregation examples.
When this renders the aggregation math has been calculated correctly, but the first row doesn't have an index, so it won't have any values (other than the '---' I included) and changes aren't used in further calculations.
I got my issue fixed, I sum it up to inexperience with JavaScript.
The aggregate rows do return an undefined in their row index, I don't know if there is a better way or not, but I worked around it with a simple if cellInfo.index !== undefined.
I hope yours is as simple of a fix!
@TomFaulkner can you please show me this part of your code?
@johnnyignatov Sure, here you go. I've edited a bit more, removing the dangerouslySetInnerHTML as well, so it will be somewhat different from the examples.
Also, you may have to remove the Semantic UI and Redux imports. But, it should be easy enough to strip those out.
FYI: Aggregated rows have no index because they are not real rows so cannot reference an index in the original data.
Most helpful comment
FYI: Aggregated rows have no index because they are not real rows so cannot reference an index in the original data.