Skip to content

Commit

Permalink
Add ignore/allow urls config option
Browse files Browse the repository at this point in the history
  • Loading branch information
jairo-mendoza committed Jan 23, 2025
1 parent 4f1e605 commit 75d5cfd
Showing 1 changed file with 13 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,12 @@ export interface ResourceFetchCustomAttributeFunction {
*/
export interface DocumentLoadInstrumentationConfig
extends InstrumentationConfig {
/**
* URLs that partially match any regex or exactly match strings in allowUrls
* will be traced.
*/
allowUrls?: Array<string | RegExp>;

/** Function for adding custom attributes on the document load, document fetch and or resource fetch spans */
applyCustomAttributesOnSpan?: {
documentLoad?: DocumentLoadCustomAttributeFunction;
Expand Down Expand Up @@ -69,4 +75,11 @@ export interface DocumentLoadInstrumentationConfig
* firstPaint
*/
ignorePerformancePaintEvents?: boolean;

/**
* URLs that partially match any regex in ignoreUrls will not be traced.
* In addition, URLs that are _exact matches_ of strings in ignoreUrls will
* also not be traced.
*/
ignoreUrls?: Array<string | RegExp>;
}

0 comments on commit 75d5cfd

Please sign in to comment.