diff --git a/core/instrument/src/babel/extract-component.ts b/core/instrument/src/babel/extract-component.ts index fc9e07ff3..0aef7de8d 100644 --- a/core/instrument/src/babel/extract-component.ts +++ b/core/instrument/src/babel/extract-component.ts @@ -80,7 +80,9 @@ export const extractComponent = async ( ...acc, [from]: [ ...acc[from], - { name, from, importedName, key: importKey }, + key + ? { name, from, importedName, key: importKey } + : { name, from, importedName }, ], }; }