-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
feat(fonts): config #12777
feat(fonts): config #12777
Conversation
|
This comment was marked as outdated.
This comment was marked as outdated.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good so far
|
||
export interface FontProvider<TName extends string> { | ||
name: TName; | ||
entrypoint: string; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
entrypoint
should be a string or a URL
. Since v5, all entry points now accept URL
too
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll address this in the next PR
export function adobe(config: { apiKey: string }) { | ||
return defineFontProvider({ | ||
name: 'adobe', | ||
entrypoint: 'astro/assets/fonts/providers/adobe', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Entrypoints should have the file extension. E.g. astro/assets/fonts/providers/adobe.js
Changes
Testing
Adds some types and config tests
Docs
N/A