@adobe/helix-rum-enhancer 1.15.3 → 1.17.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +14 -0
- package/package.json +1 -1
- package/src/index.js +6 -10
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,17 @@
|
|
|
1
|
+
# [1.17.0](https://github.com/adobe/helix-rum-enhancer/compare/v1.16.0...v1.17.0) (2024-05-07)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Features
|
|
5
|
+
|
|
6
|
+
* enable reportAll for all projects ([0e295ff](https://github.com/adobe/helix-rum-enhancer/commit/0e295ffd65fa72962b397b85b0355fd066163086))
|
|
7
|
+
|
|
8
|
+
# [1.16.0](https://github.com/adobe/helix-rum-enhancer/compare/v1.15.3...v1.16.0) (2024-05-06)
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Features
|
|
12
|
+
|
|
13
|
+
* **missingresource:** remove feature flag (1.x) ([0bad440](https://github.com/adobe/helix-rum-enhancer/commit/0bad4407a2190eccb0298ce58b60b571aab3e9b3))
|
|
14
|
+
|
|
1
15
|
## [1.15.3](https://github.com/adobe/helix-rum-enhancer/compare/v1.15.2...v1.15.3) (2024-04-22)
|
|
2
16
|
|
|
3
17
|
|
package/package.json
CHANGED
package/src/index.js
CHANGED
|
@@ -107,7 +107,6 @@ sampleRUM.drain('cwv', (() => {
|
|
|
107
107
|
sampleRUM('cwv', data);
|
|
108
108
|
};
|
|
109
109
|
|
|
110
|
-
const featureToggle = () => ['blog.adobe.com', 'www.revolt.tv'].includes(window.location.hostname);
|
|
111
110
|
const isEager = (metric) => ['CLS', 'LCP'].includes(metric);
|
|
112
111
|
|
|
113
112
|
// When loading `web-vitals` using a classic script, all the public
|
|
@@ -115,7 +114,7 @@ sampleRUM.drain('cwv', (() => {
|
|
|
115
114
|
['FID', 'INP', 'TTFB', 'CLS', 'LCP'].forEach((metric) => {
|
|
116
115
|
const metricFn = window.webVitals[`on${metric}`];
|
|
117
116
|
if (typeof metricFn === 'function') {
|
|
118
|
-
const opts = isEager(metric) ? { reportAllChanges:
|
|
117
|
+
const opts = isEager(metric) ? { reportAllChanges: true } : undefined;
|
|
119
118
|
metricFn(storeCWV, opts);
|
|
120
119
|
}
|
|
121
120
|
});
|
|
@@ -182,14 +181,11 @@ new PerformanceObserver((list) => {
|
|
|
182
181
|
.forEach((entry) => {
|
|
183
182
|
sampleRUM('loadresource', { source: entry.name, target: Math.round(entry.duration) });
|
|
184
183
|
});
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
sampleRUM('missingresource', { source: entry.name, target: entry.hostname });
|
|
191
|
-
});
|
|
192
|
-
}
|
|
184
|
+
list.getEntries()
|
|
185
|
+
.filter((entry) => entry.responseStatus === 404)
|
|
186
|
+
.forEach((entry) => {
|
|
187
|
+
sampleRUM('missingresource', { source: entry.name, target: entry.hostname });
|
|
188
|
+
});
|
|
193
189
|
}).observe({ type: 'resource', buffered: true });
|
|
194
190
|
|
|
195
191
|
[...new URLSearchParams(window.location.search).entries()]
|