Skip to content

Commit

Permalink
Add property resource_url to LCP
Browse files Browse the repository at this point in the history
  • Loading branch information
RomanGaignault committed Jan 28, 2025
1 parent a48cdd6 commit a988f34
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 1 deletion.
4 changes: 4 additions & 0 deletions lib/cjs/generated/rum.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1593,6 +1593,10 @@ export interface ViewPerformanceData {
* CSS selector path of the largest contentful paint element
*/
readonly target_selector?: string;
/**
* URL of the largest contentful paint element
*/
readonly resource_url?: string;
[k: string]: unknown;
};
[k: string]: unknown;
Expand Down
4 changes: 4 additions & 0 deletions lib/esm/generated/rum.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1593,6 +1593,10 @@ export interface ViewPerformanceData {
* CSS selector path of the largest contentful paint element
*/
readonly target_selector?: string;
/**
* URL of the largest contentful paint element
*/
readonly resource_url?: string;
[k: string]: unknown;
};
[k: string]: unknown;
Expand Down
3 changes: 2 additions & 1 deletion samples/rum-events/view.json
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,8 @@
},
"lcp": {
"timestamp": 20000000,
"target_selector": "#foo"
"target_selector": "#foo",
"resource_url": "https://example.com/foo.jpg"
}
}
},
Expand Down
5 changes: 5 additions & 0 deletions schemas/rum/_view-performance-schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,11 @@
"description": "CSS selector path of the largest contentful paint element",
"$comment": "Replaces the deprecated `view.largest_contentful_paint_target_selector`",
"readOnly": true
},
"resource_url": {
"type": "string",
"description": "URL of the largest contentful paint element",
"readOnly": true
}
},
"readOnly": true
Expand Down

0 comments on commit a988f34

Please sign in to comment.