访问网页版上来就要下载字体资源文件消耗时间

未关闭
#29 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
3/5
预计耗时
1-2 天
新手友好度
45/100
Issue 类型
功能
描述清晰度
基本清楚
活跃度
活跃
技术栈
dart, flutter
领域
performance

调研方向

The complaint is that the Flutter web build blocks first paint on a ~9MB HarmonyOS Black font download. Start by finding where that font is declared and bundled (the font entries in pubspec.yaml and the web bootstrap in web/index.html), then measure the initial load to confirm the font is the bottleneck. From there the work is either subsetting the font to the glyphs actually used, deferring it so text renders with a fallback first, or serving it in a compressed/woff2 form — done when first contentful paint no longer waits on the full font file.

由索引模型根据 Issue 内容生成。

描述

访问网页版先下载鸿蒙黑体,大约9MB,压缩后也约6MB,对弱网环境很不友好,尤其是低带宽服务器,像是那种2h2g3M的,下载这个资源文件就要占满带宽,还要将近20s才能加载完毕

主要语言
Dart
星标
20
派生
9
平均合并
1 天 1 小时
30 天内合并 PR
1

环境准备

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

ILoveScratch2/TouchFish-Client 的其他 Issue

查看 ILoveScratch2/TouchFish-Client 的全部 Issue

相似的 Issue

更多 Dart Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。