【发布时间】:2017-09-29 08:01:05
【问题描述】:
我假设包react-virtual-list 在使用VirtualList 时调用setState,但这不应该导致componentDidMount 内部出现问题,对吧?
Can only update a mounted or mounting component. This usually means you called setState() on an unmounted component. This is a no-op. Please check the code for the vlist component.
componentDidMount = () => {
this.MyVirtualList = VirtualList({container: this._itemsList})(this.MyList)
}
【问题讨论】:
-
你能贴出组成你的组件的代码吗?
-
什么是
this.MyVirtualList?那是一个功能吗?请显示更多代码。
标签: javascript reactjs