Wydajność
perf/third-party-cost
Each third-party script earns its place, loads late, and heavy embeds (video, maps, chat) start as a lightweight facade.
umiarkowanaw przeglądarcefe-perf-delivery
Dlaczego
Tag managers, chat widgets, video players and A/B testing tools often outweigh the site's own code, run long tasks during load and interaction, and change without your review. They are a common reason for poor INP and LCP.
Poprawka
List every third party with its owner and purpose; remove what nobody uses. Load the rest after the page is usable (async, defer, framework strategies, or on interaction). Replace embeds with a facade: a static preview image and a play or "load map" button that inserts the real iframe on click. Self-host small libraries instead of loading them from a CDN.
Przykłady
<!-- good: a video facade -->
<button type="button" class="video-facade" data-id="abc123">
<img src="/img/video-poster.webp" alt="" width="1280" height="720">
<span>Play video: setting up sync</span>
</button>Źródła
Fakty
- Identyfikator
perf/third-party-cost- Waga
- umiarkowana
- Sprawdzanie
- w przeglądarce wymaga wyrenderowanej strony:
audit --url - Dotyczy plików
page- Ten sam problem w
- Lighthouse
third-parties-insight - Uczy jej skill
fe-perf-deliveryJavaScript, CSS and asset delivery- Od wersji
- 0.1.0
Przeczytaj w terminalu
npx github:dawidolko/frontend-skills explain perf/third-party-cost