2017-03-29 4 views
0

lutte sur ImmutableJS ... CONNAÎTRE erreur:Immutable.js - TypeError:. Get (...) tojs n'est pas une fonction

TypeError: this.props.dataTable.get(...).toJS is not a function

relatif à cette ligne:

let tbodyRows = this.props.dataTable.get('data').toJS(); 

Lorsque Je fais console.log this.props.dataTable.get('data') Je reçois Array [1] et ce tableau contient un seul objet de données (ce qui est ce à quoi je m'attendrais).

Répondre

0

Pour utiliser .toJS(), this.props.dataTable.get('data') devrait être un List retournaient (dans ce cas) pas Array.