Skip to content

feat(fonts): getFontBuffer()#13041

Merged
florian-lefebvre merged 5 commits intomainfrom
feat/get-font-buffer
Jan 22, 2026
Merged

feat(fonts): getFontBuffer()#13041
florian-lefebvre merged 5 commits intomainfrom
feat/get-font-buffer

Conversation

@florian-lefebvre
Copy link
Member

Description (required)

Related issues & labels (optional)

  • Closes #
  • Suggested label:

For Astro version: 5.16.x. See astro PR #15182.

@netlify
Copy link

netlify bot commented Jan 13, 2026

Deploy Preview for astro-docs-2 ready!

Name Link
🔨 Latest commit 6c4cf78
🔍 Latest deploy log https://app.netlify.com/projects/astro-docs-2/deploys/6970f16304be7600083a8391
😎 Deploy Preview https://deploy-preview-13041--astro-docs-2.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@astrobot-houston
Copy link
Contributor

astrobot-houston commented Jan 13, 2026

Lunaria Status Overview

🌕 This pull request will trigger status changes.

Learn more

By default, every PR changing files present in the Lunaria configuration's files property will be considered and trigger status changes accordingly.

You can change this by adding one of the keywords present in the ignoreKeywords property in your Lunaria configuration file in the PR's title (ignoring all files) or by including a tracker directive in the merged commit's description.

Tracked Files

File Note
en/reference/experimental-flags/fonts.mdx Source changed, localizations will be marked as outdated.
Warnings reference
Icon Description
🔄️ The source for this localization has been updated since the creation of this pull request, make sure all changes in the source have been applied.


### `getFontData()`
<p>
The [`getFontBuffer()`](#getfontbuffer) function can then be used on retrieved URLs to get font buffers, for example, in an [API Route](/en/guides/endpoints/#server-endpoints-api-routes) to generate OpenGraph images using [satori](https://github.com/vercel/satori), combined with proper [formats](#formats) configuration:
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wanted to mention formats when introducing this new option but forgot. Basically satori does not support woff2 so to use Astro fonts with it, you basically always need to set formats. I thought quickly mentioning here would be good

@florian-lefebvre florian-lefebvre marked this pull request as ready for review January 21, 2026 14:00
Copy link
Member

@sarah11918 sarah11918 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@sarah11918 sarah11918 added add new content Document something that is not in docs. May require testing, confirmation, or affect other pages. merge-on-release Don't merge this before the feature is released! (MQ=approved but WAIT for feature release!) labels Jan 21, 2026
Copy link
Member

@ArmandPhilippot ArmandPhilippot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, except a Since. 😅

@florian-lefebvre florian-lefebvre merged commit ab2f0c0 into main Jan 22, 2026
10 checks passed
@florian-lefebvre florian-lefebvre deleted the feat/get-font-buffer branch January 22, 2026 09:49
@sarah11918 sarah11918 added the 6.0 label Jan 22, 2026
@sarah11918 sarah11918 added this to the v6.0.0 docs milestone Jan 22, 2026
ArmandPhilippot added a commit to ArmandPhilippot/astro-docs that referenced this pull request Jan 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

6.0 add new content Document something that is not in docs. May require testing, confirmation, or affect other pages. merge-on-release Don't merge this before the feature is released! (MQ=approved but WAIT for feature release!)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants