diff --git a/src/utils/storage.ts b/src/utils/storage.ts index 1aaf1c8..8332841 100644 --- a/src/utils/storage.ts +++ b/src/utils/storage.ts @@ -130,8 +130,10 @@ export function useStorage( function createEditor(): Editor { const current = tab() - invoke('send_trace', { text: `computing editor for tab ${current?.title} and line count ${current?.lines.length}` }) - .then(() => { }) + queueMicrotask(() => { + invoke('send_trace', { text: `computing editor for tab ${current?.title} and line count ${current?.lines.length}` }) + .then(() => { }) + }) return new Editor( current?.lines ?? ['Nothing yet.'],