feat(frontend-plugin-api): fix default app plugin id

Signed-off-by: Camila Belo <camilaibs@gmail.com>
This commit is contained in:
Camila Belo
2024-01-25 09:22:26 +01:00
parent 87f3d69dc5
commit 01abfa9c2b
3 changed files with 2 additions and 5 deletions
@@ -37,7 +37,7 @@ export const useAnalyticsContext = (): AnalyticsContextValue => {
// Provide a default value if no value exists.
if (theContext === undefined) {
return {
pluginId: 'root',
pluginId: 'app',
extensionId: 'App',
};
}
@@ -25,9 +25,6 @@ export type CommonAnalyticsContext = {
*/
pluginId: string;
/**
* The nearest known parent extension where the event was captured.
*/
/**
* The nearest known parent extension where the event was captured.
*/
@@ -65,7 +65,7 @@ export function ExtensionBoundary(props: ExtensionBoundaryProps) {
// Skipping "routeRef" attribute in the new system, the extension "id" should provide more insight
const attributes = {
extensionId: node.spec.id,
pluginId: node.spec.source?.id,
pluginId: node.spec.source?.id ?? 'app',
};
return (