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
What are font types other than .ttf which works with the react-pdf/renderer?
The documentation doesn't provide any information on supported font types.
I want to use woff2 (or atleast woff) for my use case but they are not working. I'm trying to render non-latin fonts and the .ttf files are HUGE (>9MB) for each variant (by variant, I mean regular, bold, italic, etc.). So if I want to load 1 font family of 4-5 variations usng .ttf files, it is like 40-50MB!! This is too much data and will be a bad user experience (especially for the users whoo have low speed internet connections).
The best part of woff2 fonts is they are small in size and loads quicker than .ttf fonts.
So is there any way we can use woff2 fonts for non-latin fonts (eg. Japanese)?
Note: I have already gone through this issue, where the author has pushed a commit to support woff2 fonts and closed the ticket, but there is no clear example on how to implement woff2 fonts (if at all it works)
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
What are font types other than .ttf which works with the react-pdf/renderer?
The documentation doesn't provide any information on supported font types.
I want to use woff2 (or atleast woff) for my use case but they are not working. I'm trying to render non-latin fonts and the .ttf files are HUGE (>9MB) for each variant (by variant, I mean regular, bold, italic, etc.). So if I want to load 1 font family of 4-5 variations usng .ttf files, it is like 40-50MB!! This is too much data and will be a bad user experience (especially for the users whoo have low speed internet connections).
The best part of woff2 fonts is they are small in size and loads quicker than .ttf fonts.
So is there any way we can use woff2 fonts for non-latin fonts (eg. Japanese)?
Note: I have already gone through this issue, where the author has pushed a commit to support woff2 fonts and closed the ticket, but there is no clear example on how to implement woff2 fonts (if at all it works)
Beta Was this translation helpful? Give feedback.
All reactions