State and Lifecycle 這一節里面有兩個地方不太懂1. State Updates are MergedThe merging is shallow, so this.setState({comments}) leaves this.state.posts intact, but completely replaces this.state.comments.我的理解是,在多個異步請求都在調用this.setState()的時候,react會等到最后一個請求返回后,this.setState()才會更新視圖,在此之前的this.setState()做的都是合并this.state這個對象的操作。這個理解有問題么?如果沒問題的話,上面這段引用應該如何翻譯?
看React官方文檔的點小疑惑
呼如林
2019-03-19 17:13:01