-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Incorrect guide for accessing font programatically through Fonts API #13635
Copy link
Copy link
Open
Labels
improve or update documentationEnhance / update existing documentation (e.g. add example, improve description, update for changes)Enhance / update existing documentation (e.g. add example, improve description, update for changes)
Description
📚 Subject area/topic
Fonts API
📋 Page(s) affected (or suggested, for new content)
https://docs.astro.build/en/guides/fonts/#accessing-font-data-programmatically
📋 Description of content that is out-of-date or incorrect
context.url.origin will resolve to the Astro.site string in astro build production mode. Meaning the font already has to be deployed for this fetch to work. Fix could be to use readfile and stuff rather than involving urls.
Also, it is useful to mention that satori doesn't use woff2 format.
This particular guide is very useful but it has to be bug free and descriptive. Almost everyone wants og image for their blog so that it looks more personalised when shared on the internet.
🖥️ Reproduction in StackBlitz (if reporting incorrect content or code samples)
No response
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
improve or update documentationEnhance / update existing documentation (e.g. add example, improve description, update for changes)Enhance / update existing documentation (e.g. add example, improve description, update for changes)