界面已本地化;技能介绍与说明文档按所选语言由 AI 自动翻译,代码、命令、路径和专业术语保留原文,以原作者文档为准。
探索技能
数据与研究 · SKILL.md

font-loading

font-loading

【数据与研究】Use when auditing slow page loads, heavy assets, or rendering delays related to Optimize web font loading. Verify the actual bottleneck in DevTools, Lighthouse, or field data before recommending changes.

独立 GitHub 快照 · 自动分类 · 以原作者文档为准

技能说明

GitHub

name: font-loading description: "Use when auditing slow page loads, heavy assets, or rendering delays related to Optimize web font loading. Verify the actual bottleneck in DevTools, Lighthouse, or field data before recommending changes." metadata: category: performance priority: high difficulty: intermediate estimatedTime: "15" source: frontendchecklist.io url: https://frontendchecklist.io/rules/performance/font-loading

Optimize web font loading

Slow font loading can cause 'Flash of Invisible Text' (FOIT) or significant layout shifts, negatively impacting both user experience and Core Web Vitals.

Quick Reference

  • Use font-display: swap to prevent invisible text during load
  • Preload critical fonts to discover them earlier
  • Use modern formats like WOFF2 for better compression

Check

Check font loading strategies and verify that font-display is used and critical fonts are preloaded.

Fix

Add font-display: swap to @font-face declarations and use <link rel='preload'> for the most important fonts.

Explain

Explain how font loading affects perceived performance and layout stability.

Code Review

Review the routes, assets, and loading behavior that affect Optimize web font loading. Flag exact files, requests, or rendering steps that add unnecessary network, CPU, or layout cost, and describe the measurement method used to confirm the issue.


For full implementation details, code examples, and framework-specific guidance, see references/rule.md.

Rule page: https://frontendchecklist.io/rules/performance/font-loading

我的收藏