Skip to content
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

3.19 - Preconnect to external domains - Self-Host Google Fonts compatibility #7292

Open
piotrbak opened this issue Feb 6, 2025 · 1 comment
Milestone

Comments

@piotrbak
Copy link
Contributor

piotrbak commented Feb 6, 2025

User Story

As a user, I want to make sure that the feature is compatible with Self-Host Google Fonts

Acceptance Criteria

  • If all fonts are self-hosted, no preconnect
  • If there’s an exclusion and some of the fonts are hosted by Google, preconnect needed
@piotrbak piotrbak added this to the 3.19-alpha milestone Feb 6, 2025
@wordpressfan
Copy link
Contributor

Here:

if ( $this->is_excluded( $item['href'], $exclusions ) ) {

we are in the loop of head items, and here we check if this font is excluded so here we can add the preconnect item.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants