-
Notifications
You must be signed in to change notification settings - Fork 4
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
Feature request: get fonts data or url #2
Comments
Hey @florian-lefebvre, With the recently released version, now all the font files are present in a astro-font specific directory: https://github.com/rishi-raj-jain/astro-font/blob/master/packages/astro-font/utils.ts#L89 Does this solve your use case? |
Btw, love the support! Happy to improve the library. |
I can't try it now but it sounds good! It may be great to provide a little utility function to retrieve the data like: export const getFontData = (fontName: string): ArrayBuffer => {
// ...
} |
Looking into this. Reading upon how can I do this. |
I can use your direction here, how ideally would this function work? |
I already shared the type signature above. Regarding its behavior, you're currently fonts files inside your cache. This function would retrieve the right font data (just reading the file content really) from the font family name |
When using tools like Satori, we need to load fonts. It would be great to be able to access the data loaded in an endpoint
The text was updated successfully, but these errors were encountered: