@@ -54,23 +54,24 @@ export interface StartSpanOptions {
5454 *
5555 * @deprecated This option will be removed in the next major version of the SDK. There is no longer a concrete use
5656 * case for it: all spans are indexed and searchable in Sentry, so a span no longer needs to be a transaction to be
57- * queried, filtered or aggregated on. In most cases, simply drop the option - the span is still sent, just as a child
58- * of its parent span. If you do need the span to be a segment (root) span, start it without a parent span instead.
57+ * queried, filtered or aggregated on. In most cases, simply drop the option. The span is still sent, just as a child
58+ * of its parent span, if a parent span is active.
59+ * If you do need the span to be a segment (root) span, follow the examples below:.
5960 *
60- * @example Making a span a segment span without forcing it into a transaction
61+ * @example Making a span a root span:
6162 * ```js
6263 * Sentry.withActiveSpan(null, () => {
63- * Sentry.startSpan({ name: 'span-that-should-be-a-segment ' }, () => {
64+ * Sentry.startSpan({ name: 'span-that-should-be-a-root ' }, () => {
6465 * // ...
6566 * });
6667 * });
6768 * ```
6869 *
69- * @example Keeping that segment span attached to an incoming trace
70+ * @example Keeping the root span attached to a specific trace:
7071 * ```js
7172 * Sentry.continueTrace({ sentryTrace, baggage }, () =>
7273 * Sentry.withActiveSpan(null, () =>
73- * Sentry.startSpan({ name: 'span-that-should-be-a-segment ' }, () => {
74+ * Sentry.startSpan({ name: 'span-that-should-be-a-root ' }, () => {
7475 * // ...
7576 * }),
7677 * ),
0 commit comments