Tencent / tmagic-editor

Other
4.22k stars 714 forks source link

packages/editor/src/services/editor.ts 文件中的update方法有bug,导致父子组件更新时调用doUpdate子组件获取到info.parent是旧数据 #585

Open 841148070 opened 7 months ago

841148070 commented 7 months ago

update方法中

const newNodes = await Promise.all(nodes.map((node) => this.doUpdate(node))); 改成 const newNodes: MNode[] = []; (async () => { for (const node of nodes) { const newNode = await this.doUpdate(node) newNodes.push(newNode); } })() 后亲测可用

jia000 commented 7 months ago

什么场景的操作会同时修改到父子节点?