File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change 15
15
16
16
Quicklink 通过以下方式加快后续页面的加载速度:
17
17
18
- - ** 检测视区中的链接** (使用 [ Intersection Observer] ( https://developer.mozilla.org/en-US /docs/Web/API/Intersection_Observer_API ) )。
19
- - ** 等待浏览器空闲** (使用 [ requestIdleCallback] ( https://developer.mozilla.org/en-US /docs/Web/API/Window/requestIdleCallback ) )。
18
+ - ** 检测视区中的链接** (使用 [ Intersection Observer] ( https://developer.mozilla.org/zh-CN /docs/Web/API/Intersection_Observer_API ) )。
19
+ - ** 等待浏览器空闲** (使用 [ requestIdleCallback] ( https://developer.mozilla.org/zh-CN /docs/Web/API/Window/requestIdleCallback ) )。
20
20
- ** 确认用户并未处于慢速连接** (使用 ` navigator.connection.effectiveType ` )或启用省流模式(使用 ` navigator.connection.saveData ` )。
21
21
- ** 预获取视区内的 URL** (使用 [ ` <link rel=prefetch> ` ] ( https://www.w3.org/TR/resource-hints/#prefetch ) 或 XHR)。可根据请求优先级进行控制(若支持 fetch() 可进行切换)。
22
22
@@ -93,7 +93,7 @@ quicklink();
93
93
94
94
` quicklink ` :
95
95
96
- - [ requestIdleCallback] ( https://developer.mozilla.org/en-US /docs/Web/API/Window/requestIdleCallback ) 的一个非常小的回退。
96
+ - [ requestIdleCallback] ( https://developer.mozilla.org/zh-CN /docs/Web/API/Window/requestIdleCallback ) 的一个非常小的回退。
97
97
- 需要支持 ` IntersectionObserver ` (请参阅 [ CanIUse] ( https://caniuse.com/#feat=intersectionobserver ) )。我们推荐使用 Polyfill.io 等服务选择性地实现此功能:
98
98
99
99
``` html
@@ -254,4 +254,4 @@ Promise.all(promises);
254
254
255
255
## 许可证
256
256
257
- 本项目已获得 Apache-2.0 许可。
257
+ 本项目已获得 Apache-2.0 许可。
You can’t perform that action at this time.
0 commit comments