Skip to content

Commit b7d1544

Browse files
authored
feat(vue): Only start UI spans if parent is available (#13568)
UI spans make sense if they are a child of e.g. a pageload root span. This change ensures UI spans are not created as root spans. ref #13546
1 parent 4774399 commit b7d1544

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

packages/vue/src/tracing.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,8 @@ export const createTracingMixins = (options: TracingOptions): Mixins => {
114114
attributes: {
115115
[SEMANTIC_ATTRIBUTE_SENTRY_ORIGIN]: 'auto.ui.vue',
116116
},
117+
// UI spans should only be created if there is an active root span (transaction)
118+
onlyIfParent: true,
117119
});
118120
}
119121
} else {

0 commit comments

Comments
 (0)