Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Extreme slowdown on fonts generated by webfont #558

Open
mririgoyen opened this issue Mar 25, 2022 · 1 comment
Open

Extreme slowdown on fonts generated by webfont #558

mririgoyen opened this issue Mar 25, 2022 · 1 comment

Comments

@mririgoyen
Copy link

mririgoyen commented Mar 25, 2022

Hello there! Over at Material Design Icons, we utilize this library to turn our SVG library into webfonts for distribution. Recently, we updated from version 9 to version 11 of webfont. The fonts generate without error or issue, but we ran into something very unexpected. The newly generated font files (specifically the woff2, maybe others... need more testing) causes some browsers to hang or even crash.

Reports from our users can be seen on an open issue here: Templarian/MaterialDesign#6519

I've personally tested extensively on a known good version of our library using v9 and then v11 of webfont. The woff2 output by v11 causes the issue every time, however the v9 build does not. Interestingly enough, it exhibits the negative behavior the worst on Windows and Firefox. The slowdown is apparent in Chrome as well, but no where near as bad. I have been unable to reproduce it consistently on Mac. Our users report the issues don't happen on Linux.


To reproduce this yourself, you can follow these steps:

Get a Good Version

  1. Clone https://github.com/Templarian/MaterialDesign-SVG.
  2. Install our toolchain, requiring webfont@9.0.0: npm install -g @mdi/font-build@1.8.6
  3. Run font-build inside the cloned SVG repo.
  4. Open dist/index.html in Firefox on Windows.
  5. No issues!

Get a Bad Version

  1. Clone https://github.com/Templarian/MaterialDesign-SVG.
  2. Install our toolchain, requiring webfont@11.2.26: npm install -g @mdi/font-build
  3. Run font-build inside the cloned SVG repo.
  4. Open dist/index.html in Firefox on Windows.
  5. Firefox locks up. It may become responsive after some time or crash.

Please let me know if there is anything else we can provide to help make debugging this issue easier. Thank you!

@Templarian
Copy link

(Maintainer of Material Design Icons traveling for work) We're going try to get a simplified repo for this after narrowing down the specific version that introduced this. In the issue someone did give a DirectWrite output.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants