When using downloadable fonts, theres a slight delay before the downloaded font shows up. This looks odd, but Ive managed to work around it by using
FontFamily.Resolver.preload(...)
and only showing my content after the call finishes.
Is this a really bad idea? Considering cases where the user has no/bad connectivity, etc. Would I potentially be blocking them from accessing my app for a long time? And if thats the case, is there an alternative?
a
Albert Chang
10/27/2022, 5:56 AM
This is definitely something you need to consider and is why there is font-display descriptor in CSS.
I think you can use
withTimeout() { ... }
to achieve similar effect.
z
Zoltan Demant
10/27/2022, 10:06 AM
Oh yep, thank you. I guess Ill stick to having my fonts bundled in the app for now (+90 kb).