react-bootstrap-table icon indicating copy to clipboard operation
react-bootstrap-table copied to clipboard

Uncaught TypeError: Cannot read property 'type' of undefined

Open ryerh opened this issue 10 years ago • 4 comments

This is what I took from my console's ouput:

TableColumn.js:64 Uncaught TypeError: Cannot read property 'type' of undefined
  shouldComponentUpdate @ TableColumn.js:64
  updateComponent       @ ReactCompositeComponent.js:656
  receiveComponent      @ ReactCompositeComponent.js:571
  receiveComponent      @ ReactReconciler.js:127
  ...

The error above occurred after I doing the following:

const data = [
  { id: 1, value: [<span key="1">hello</span>, <span key="2">world</span>] },
  { id: 1, value: [<span key="1">hello</span>, <span key="2">world</span>] },
];

<BootstrapTable data={data} />

ryerh avatar Sep 08 '16 07:09 ryerh

Sorry, this issue duplicates with issues/315;

ryerh avatar Sep 08 '16 07:09 ryerh

HI @ryerh, so everything is ok? I'll open it if this problem still remain. Thanks

AllenFang avatar Sep 08 '16 13:09 AllenFang

I am getting this error

main.js:19136 TypeError: Cannot read property 'type' of undefined at ArticleListCtrl.runQuery (main.js:39784) at ArticleListCtrl.setListTo (main.js:39765) at new ArticleListCtrl (main.js:39745) at Object.invoke (main.js:9614) at $controllerInit (main.js:15477) at nodeLinkFn (main.js:14357) at main.js:14765 at processQueue (main.js:21443) at main.js:21487 at Scope.$digest (main.js:22582)

Javril avatar Apr 12 '17 02:04 Javril

I am getting the same error mentioned in the title of this ticket, so won't open a new ticket.

I am getting the error: Uncaught TypeError: Cannot read property 'Pallet' of undefined

(anonymous) TableBody.js:163
  (anonymous) TableBody.js:162
  render TableBody.js:161
  _renderValidatedComponentWithoutOwnerOrContext ReactCompositeComponent.js:832
  _renderValidatedComponent ReactCompositeComponent.js:859
  _updateRenderedComponent ReactCompositeComponent.js:782
  _performComponentUpdate ReactCompositeComponent.js:753
  updateComponent ReactCompositeComponent.js:670
  receiveComponent ReactCompositeComponent.js:564
  receiveComponent ReactReconciler.js:129
  updateChildren ReactChildReconciler.js:107
  _reconcilerUpdateChildren ReactMultiChild.js:213
  _updateChildren ReactMultiChild.js:316
  updateChildren ReactMultiChild.js:303
  _updateDOMChildren ReactDOMComponent.js:960
  updateComponent ReactDOMComponent.js:780
  receiveComponent ReactDOMComponent.js:734
  receiveComponent ReactReconciler.js:129
  updateChildren ReactChildReconciler.js:107
  _reconcilerUpdateChildren ReactMultiChild.js:213
  _updateChildren ReactMultiChild.js:316
  updateChildren ReactMultiChild.js:303
  _updateDOMChildren ReactDOMComponent.js:960
  updateComponent ReactDOMComponent.js:780
  receiveComponent ReactDOMComponent.js:734
  receiveComponent ReactReconciler.js:129
  _updateRenderedComponent ReactCompositeComponent.js:784
  _performComponentUpdate ReactCompositeComponent.js:753
  updateComponent ReactCompositeComponent.js:670
  performUpdateIfNecessary ReactCompositeComponent.js:578
  performUpdateIfNecessary ReactReconciler.js:163
  runBatchedUpdates ReactUpdates.js:151

Irrespective of returning false from shouldComponentUpdate, I am getting this error. Seems like the table still renders. Am I missing anything here? Some more info: After returning false, componentWillUpdate and render function are not being called in the component. shouldComponentUpdate is called as a result of updating the state. It would be great if you could reply to this.

Thanks :)

pbtanna17 avatar Aug 07 '17 21:08 pbtanna17