-
-
Notifications
You must be signed in to change notification settings - Fork 118
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
Add FontFace component #77
base: master
Are you sure you want to change the base?
Conversation
When reviewing especially keep an eye on:
|
interesting use of suspense. why not offer |
No, it's absolutely a valid comment. In fact, I thought about <FontFace
family="Name"
source="url(path/to/name.woff2) format('woff2'), url(path/to/name.woff) format('woff')" /> This is great to provide fallbacks if the preferred format is not supported or to refer to a local font as the primary option. An alternative API could be using <FontFace
family="Name"
source={[
{
url: 'path/to/name.woff2',
format: 'woff2',
},
{
url: 'path/to/name.woff',
format: 'woff',
},
]}
/> |
hmm, yea i see. idk, you can also leave it as a string and ask for OSS to write validation regex :) |
You do get limited runtime feedback. If you call |
β¨ Add FontFace resource
π Document
<FontFace \>
anduseFontFace
π Add
<FontFace />
exampleResolves #76