Skip to content

rustdoc: add optional woff2 versions of FiraSans. - #82545

Merged
bors merged 2 commits into
rust-lang:masterfrom
jsha:woff2
Feb 26, 2021
Merged

rustdoc: add optional woff2 versions of FiraSans.#82545
bors merged 2 commits into
rust-lang:masterfrom
jsha:woff2

Conversation

@jsha

@jshajsha commented Feb 26, 2021

Copy link
Copy Markdown
Contributor

For browsers that support woff2 (most modern ones:
https://caniuse.com/woff2), this offers a reduction in download size
for these two fonts from 362k to 257k (32% reduction). It decreases the
total page size for struct.String.html (counting all subresources) by
about 2.5%.

If this is interesting, I'm happy to apply the same treatment to the
other fonts, but these two are the biggest.

For browsers that support woff2 (most modern ones:
https://caniuse.com/woff2), this offers a reduction in download size
for these two fonts from 362k to 257k (32% reduction). It decreases the
total page size for `struct.String.html` (counting all subresources) by
about 2.5%.
If this is interesting, I'm happy to apply the same treatment to the
other fonts, but these two are the biggest.
@rust-highfive

Copy link
Copy Markdown
Contributor

Some changes occurred in HTML/CSS/JS.

cc @GuillaumeGomez

@rust-highfive

Copy link
Copy Markdown
Contributor

r? @jyn514

(rust-highfive has picked a reviewer for you, use r? to override)

@rust-highfiverust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Feb 26, 2021
@jshajsha changed the title Add optional woff2 versions of FiraSans.rustdoc: add optional woff2 versions of FiraSans.Feb 26, 2021
@GuillaumeGomez

Copy link
Copy Markdown
Member

That's nice, thanks!

New static files, ping @rust-lang/docs-rs !

@bors: r+ rollup

@bors

bors commented Feb 26, 2021

Copy link
Copy Markdown
Collaborator

📌 Commit ad7ed13 has been approved by GuillaumeGomez

@borsbors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Feb 26, 2021
@Nemo157

Copy link
Copy Markdown
Contributor

(just as a sanity check I confirmed these are the files from https://github.com/mozilla/Fira/releases/tag/4.202)

GuillaumeGomez added a commit to GuillaumeGomez/rust that referenced this pull request Feb 26, 2021
rustdoc: add optional woff2 versions of FiraSans.
For browsers that support woff2 (most modern ones:
https://caniuse.com/woff2), this offers a reduction in download size
for these two fonts from 362k to 257k (32% reduction). It decreases the
total page size for `struct.String.html` (counting all subresources) by
about 2.5%.
If this is interesting, I'm happy to apply the same treatment to the
other fonts, but these two are the biggest.
GuillaumeGomez added a commit to GuillaumeGomez/rust that referenced this pull request Feb 26, 2021
rustdoc: add optional woff2 versions of FiraSans.
For browsers that support woff2 (most modern ones:
https://caniuse.com/woff2), this offers a reduction in download size
for these two fonts from 362k to 257k (32% reduction). It decreases the
total page size for `struct.String.html` (counting all subresources) by
about 2.5%.
If this is interesting, I'm happy to apply the same treatment to the
other fonts, but these two are the biggest.
This was referenced Feb 26, 2021
bors added a commit to rust-lang-ci/rust that referenced this pull request Feb 26, 2021
…laumeGomez
Rollup of 8 pull requests
Successful merges:
- rust-lang#81940 (Stabilize str_split_once)
- rust-lang#82165 (Reword labels on E0308 involving async fn return type)
- rust-lang#82456 (Replaced some unwrap_or and map_or with lazy variants)
- rust-lang#82491 (Consider inexpensive inlining criteria first)
- rust-lang#82506 (Properly account for non-shorthand pattern field in unused variable lint)
- rust-lang#82535 (Set codegen thread names)
- rust-lang#82545 (rustdoc: add optional woff2 versions of FiraSans.)
- rust-lang#82549 (Revert "Update normalize.css to 8.0.1")
Failed merges:
r? `@ghost`
`@rustbot` modify labels: rollup
@bors
bors merged commit b4ded5a into rust-lang:masterFeb 26, 2021
@rustbotrustbot added this to the 1.52.0 milestone Feb 26, 2021
@jsha
jsha deleted the woff2 branch February 27, 2021 00:13
JohnTitor added a commit to JohnTitor/rust that referenced this pull request Jun 22, 2021
rustdoc: add optional woff2 versions of Source Serif and Source Code
This provides woff2 versions of Source Serif and Source Code similar to how rust-lang#82545 provides woff2 versions of Fira Sans. The total byte count for the six files (three for each font family) is reduced by 25% from 476 KiB to 358 KiB.
JohnTitor added a commit to JohnTitor/rust that referenced this pull request Jun 22, 2021
rustdoc: add optional woff2 versions of Source Serif and Source Code
This provides woff2 versions of Source Serif and Source Code similar to how rust-lang#82545 provides woff2 versions of Fira Sans. The total byte count for the six files (three for each font family) is reduced by 25% from 476 KiB to 358 KiB.
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-waiting-on-borsStatus: Waiting on bors to run and complete tests. Bors will change the label on completion.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants

@jsha@rust-highfive@GuillaumeGomez@bors@Nemo157@jyn514@rustbot