From ec740ee24cdc943e2f9cb4dd5e16852ddd8011a5 Mon Sep 17 00:00:00 2001 From: Eduardo San Martin Morote Date: Wed, 28 Jul 2021 12:13:14 +0200 Subject: [PATCH] feat(devtools): add sotre id information --- src/devtools/plugin.ts | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/devtools/plugin.ts b/src/devtools/plugin.ts index eda839a1..1c0ba34a 100644 --- a/src/devtools/plugin.ts +++ b/src/devtools/plugin.ts @@ -264,6 +264,7 @@ function addStoreToDevtools(app: App, store: StoreGeneric) { title: '🛫 ' + name, subtitle: 'start', data: { + store: formatDisplay(store.$id), action: formatDisplay(name), args, }, @@ -280,6 +281,7 @@ function addStoreToDevtools(app: App, store: StoreGeneric) { title: '🛬 ' + name, subtitle: 'end', data: { + store: formatDisplay(store.$id), action: formatDisplay(name), args, result, @@ -299,6 +301,7 @@ function addStoreToDevtools(app: App, store: StoreGeneric) { title: '💥 ' + name, subtitle: 'end', data: { + store: formatDisplay(store.$id), action: formatDisplay(name), args, error, @@ -319,7 +322,10 @@ function addStoreToDevtools(app: App, store: StoreGeneric) { const eventData: TimelineEvent = { time: Date.now(), title: formatMutationType(type), - data: formatEventData(events), + data: { + store: formatDisplay(store.$id), + ...formatEventData(events), + }, groupId: activeAction, } @@ -361,7 +367,7 @@ function addStoreToDevtools(app: App, store: StoreGeneric) { title: '🔥 ' + store.$id, subtitle: 'HMR update', data: { - id: formatDisplay(store.$id), + store: formatDisplay(store.$id), info: formatDisplay(`HMR update`), }, }, -- 2.47.2