site: module import waterfall leaves search inert for about 3 s on 3G; add modulepreload for each page type
維護者通常 1 天內回覆
還沒有人認領這個 Issue。
評估
- 難度
- 4/5
- 預估耗時
- 3-5 天
- 新手友好度
- 53/100
- Issue 類型
- 功能
- 描述清晰度
- 描述清楚
- 活躍度
- 活躍
- 技術堆疊
- javascript
- 領域
- performance
研究方向
Read the shared head builder, site/public/index.html, and the reported module import graph; compare the built pages in site/dist/index.html. Add the page specific modulepreload links and update or add a page check that asserts each built page preloads every module it loads. Done when the check passes and, under the stated Fast 3G emulation, shared.mjs finishes within one round trip of app.js.
由索引模型根據 Issue 內容生成。
描述
Why it matters
The homepage is prerendered so it paints fast, but the search box and filters do nothing until the whole ES-module graph and data.js have arrived. A visitor who types in the first seconds sees nothing happen, which is the one interaction the site exists for.
Evidence (at 69387df, Fast 3G / 4x CPU emulation on the local build)
- Resource
responseEnd:app.js1243 ms;search.js,cards.mjs,views.js,owes.js2344-2369 ms (second round trip, discovered only afterapp.jsis parsed);shared.mjs2927 ms (third round trip, imported bycards.mjs);data.js1794 ms (355 KB raw, 79 KB gzip). - Import graph:
app.js->search.js,cards.mjs,views.js;cards.mjs->shared.mjs;shortlist.js->owes.js. site/dist/index.htmlcontains nomodulepreloadlinks (only two font preloads).site/public/index.html:227-229loadsdata.jswithdeferplus two module scripts.
Suggested approach
Have the shared head builder emit <link rel="modulepreload" href="..."> for the exact module set each page type uses (home: 7 files; entry: entry.js, shortlist.js, owes.js; category: category.js, views.js, shortlist.js, owes.js) so every module fetches in parallel with data.js. Optionally fetchpriority="high" on data.js, and consider moving the summary field (about 78 KB of the payload) out of data.js if a slimmer payload is wanted.
Done when
In the same emulation, shared.mjs finishes within one round trip of app.js; a page-check asserts every built page has a modulepreload per module it loads.
- 主要語言
- JavaScript
- 星號
- 58
- 分支
- 15
- 平均合併
- 18 小時 42 分鐘
- 30 天內合併 PR
- 11
環境準備
- 沒有 Dockerfile 或 Docker Compose 檔案
- 有 Pull Request 範本
- 閱讀貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
TMHSDigital/Free-Game-Dev-Assets 的其他 Issue
-
community marketing priority: low
難度 2/5 1-3 小時 新手友好度 72/100
TMHSDigital/Free-Game-Dev-Assets#151 ·
維護者通常 1 天內回覆
-
documentation priority: medium
難度 2/5 1-3 小時 新手友好度 78/100
TMHSDigital/Free-Game-Dev-Assets#72 ·
維護者通常 1 天內回覆
-
enhancement
難度 1/5 1-3 小時 新手友好度 68/100
TMHSDigital/Free-Game-Dev-Assets#3 · 1 則留言 ·
維護者通常 1 天內回覆
-
correction
難度 2/5 1-3 小時 新手友好度 57/100
TMHSDigital/Free-Game-Dev-Assets#162 ·
維護者通常 1 天內回覆
-
marketing priority: low
難度 2/5 1-3 小時 新手友好度 55/100
TMHSDigital/Free-Game-Dev-Assets#152 ·
維護者通常 1 天內回覆
查看 TMHSDigital/Free-Game-Dev-Assets 的全部 Issue
相似的 Issue
-
external-plugin ready-for-review third party
難度 2/5 1-3 小時 新手友好度 68/100
github/awesome-copilot#5713 · 1 則留言 ·
維護者通常 1 天內回覆
-
Mend: dependency security vulnerability
難度 2/5 1-3 小時 新手友好度 68/100
carbon-design-system/carbon-react-router-starter#1005 ·
維護者通常 1 天內回覆
-
enhancement p2 setup
難度 1/5 1 小時以內 新手友好度 88/100
維護者通常 1 天內回覆
-
難度 2/5 1-3 小時 新手友好度 72/100
維護者通常 1 天內回覆
-
bug good first issue query-log web
難度 2/5 1-3 小時 新手友好度 85/100
ferrous-networking/ferrous-dns#326 ·
維護者通常 1 天內回覆