You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Translation of javascript chapter to Japanese (#3310)
* Translation of javascript chapter to Japanese
* Fix async-defer link
* Fix another link
* Add to 2022.json
* Un-internationalise links
* fix of translation omissions
Co-authored-by: Barry Pollard <barrypollard@google.com>
Copy file name to clipboardExpand all lines: src/content/en/2022/javascript.md
+5-5Lines changed: 5 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -207,7 +207,7 @@ The `type="module"` and `nomodule` attributes are specific to the presence (or a
207
207
208
208
It's encouraging that 76% of mobile pages load scripts with `async`, as that suggests developers are cognizant of the effects of render blocking. However, such a low usage of `defer` suggests that there are opportunities being left on the table to improve rendering performance.
209
209
210
-
As noted [last year](../2021/javascript/#async-and-defer), using both `async` and `defer` is an antipattern that should be avoided as the `defer` part is ignored and `async` takes precedence.
210
+
As noted [last year](../2021/javascript#async-and-defer), using both `async` and `defer` is an antipattern that should be avoided as the `defer` part is ignored and `async` takes precedence.
211
211
212
212
The general absence of `type="module"` and `nomodule` is not surprising, as few pages seem to be shipping JavaScript modules. As time goes on, the usage of `type="module"` in particular may increase, as developers ship untransformed JavaScript modules to the browser.
213
213
@@ -334,7 +334,7 @@ Unfortunately, we see five `preload` hints for JavaScript resources at the 90th
334
334
{{ figure_markup(
335
335
image="modulepreload.png",
336
336
caption="Distribution of `modulepreload` adoption for JavaScript resources per page.",
337
-
description="Bar chart showing the 10, 25, 50, 75, and 90th percentiles of modulepreload hints for JavaScript resources per page. The values for mobile pages are 1, 1, 2, 6, and 14, respectively. Desktop values are nearly identical to mobile..",
337
+
description="Bar chart showing the 10, 25, 50, 75, and 90th percentiles of modulepreload hints for JavaScript resources per page. The values for mobile pages are 1, 1, 2, 6, and 14, respectively. Desktop values are nearly identical to mobile.",
@@ -648,7 +648,7 @@ The first of these is <a hreflang="en" href="https://web.dev/fid/">First Input D
648
648
{{ figure_markup(
649
649
image="fid.png",
650
650
caption="The distribution of websites' 75th percentile FID values.",
651
-
description="Bar chart showing the 10, 25, 50, 75 and 90th percentiles of origin's 75th percentile FID values. All values are 0 ms until the 90th percentile, where both desktop and phone are 25 ms.'",
651
+
description="Bar chart showing the 10, 25, 50, 75 and 90th percentiles of origin's 75th percentile FID values. All values are 0 ms until the 90th percentile, where both desktop and phone are 25 ms.",
@@ -777,7 +777,7 @@ Avoid using synchronous XHR, and XHR in general. `fetch` is a much more ergonomi
777
777
778
778
Before the introduction of DOM insertion methods ([`appendChild`](https://developer.mozilla.org/docs/Web/API/Node/appendChild) and others, for example), <ahreflang="en"href="https://developer.mozilla.org/docs/Web/API/Document/write">`document.write`</a> was used to insert content at the position the `document.write` was made in the document.
779
779
780
-
`document.write` is very problematic. For one, it blocks the HTML parser, and is problematic for a number of other reasons <ahreflang="en"href="https://html.spec.whatwg.org/multipage/dynamic-markup-insertion.html#document.write(">the HTML spec itself warns against its use</a>). On slow connections, blocking document parsing to append nodes in this way creates performance problems that are entirely avoidable.
780
+
`document.write` is very problematic. For one, it blocks the HTML parser, and is problematic for a number of other reasons <ahreflang="en"href="https://html.spec.whatwg.org/multipage/dynamic-markup-insertion.html#document.write()">the HTML spec itself warns against its use</a>. On slow connections, blocking document parsing to append nodes in this way creates performance problems that are entirely avoidable.
781
781
782
782
{{ figure_markup(
783
783
caption="The number of mobile pages using `document.write`.",
@@ -838,7 +838,7 @@ To understand the usage of libraries and frameworks, HTTP Archive uses [Wappalyz
838
838
)
839
839
}}
840
840
841
-
It's still no surprise that jQuery is by far the most used library on the web today. Part of that is because WordPress is used on [35%](./cms##most-popular-cmss) of sites, but even so, the majority of jQuery usage occurs outside of the WordPress platform.
841
+
It's still no surprise that jQuery is by far the most used library on the web today. Part of that is because WordPress is used on [35%](./cms#most-popular-cmss) of sites, but even so, the majority of jQuery usage occurs outside of the WordPress platform.
842
842
843
843
While jQuery is relatively small and reasonably quick at what it does, it still represents a certain amount of overhead in applications. Most of what jQuery offers is now <ahreflang="en"href="https://youmightnotneedjquery.com/">doable with native DOM APIs</a>, and may be unnecessary in today's web applications.
0 commit comments