@computed get detailMap() { // 方便获取某个 id 下的 detail
return this.details.reduce((result, detail) => {
console.log("getTopic deail.id: ", detail.id) // eslint-disable-line
result[detail.id] = detail // eslint-disable-line
console.log("getTopic result: ", result) // eslint-disable-line
return result
}, {})
}查看到的 result 是这个对象

错误
Uncaught TypeError: Cannot read property 'reduce' of undefined at Object.get (topic-store.js?a13d:52) at ComputedValue$$1.computeValue (mobx.module.js?daf9:875) at ComputedValue$$1.get (mobx.module.js?daf9:805) at ObservableObjectAdministration$$1.read (mobx.module.js?daf9:3413) at Object.get (mobx.module.js?daf9:3673) at backend.js:7516 at Array.forEach (<anonymous>) at Bridge._inspectResponse (backend.js:7512) at Bridge._handleMessage (backend.js:7393) at listener (backend.js:86)
details 内容
