Skip to content

Commit 4b09a22

Browse files
fix(component): Always updated the inspected component even if the updated hook is not triggered. (#2065)
1 parent 58ef2f7 commit 4b09a22

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

packages/app-backend-core/src/index.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -121,8 +121,8 @@ async function connect () {
121121
const sendComponentUpdate = throttle(async (appRecord: AppRecord, id: string) => {
122122
try {
123123
// Update component inspector
124-
if (id && isSubscribed(BridgeSubscriptions.SELECTED_COMPONENT_DATA, sub => sub.payload.instanceId === id)) {
125-
await sendSelectedComponentData(appRecord, id, ctx)
124+
if (ctx.currentInspectedComponentId) {
125+
await sendSelectedComponentData(appRecord, ctx.currentInspectedComponentId, ctx)
126126
}
127127

128128
// Update tree (tags)

0 commit comments

Comments
 (0)