- question
when I use the toJS method in immutable to turn an array of immutable objects into a normal array, an error occurs
error message: TypeError: list.toJS is not a function
the confusing thing is that when I went to yarn start for the first time, he would not make a mistake. He would have it later, and it would be good to restart the server, and then make changes and hot updates and then report an error QAQ
. - list items
index Code
const newList = list.toJS();
reducer Code
const defaultState = fromJS({
list: [1,2,3,4,5]
});