-
Notifications
You must be signed in to change notification settings - Fork 228
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
Add Self-host Google Fonts to the Meta Generator tag #7258
Comments
Scope a solutionIn https://github.com/wp-media/wp-rocket/blob/30e6ab6126524fe8f6717babb1360ce066b33a0f/inc/Engine/Support/Meta.php, if ( (bool) $this->options->get( 'host_fonts_locally' ) ) {
$features[] = 'wpr_host_fonts_locally';
} exactly here wp-rocket/inc/Engine/Support/Meta.php Line 121 in 30e6ab6 |
Looks good to me, if u think also that this will be needed in the future, we can have an array of options as keys and feature names as value then loop over them to check the option and add the feature name into features array, what do u think? |
I totally agree with this @wordpressfan Pretty simple tho to make it, Having a array such as: $features_to_check = [
'name_displayed_in_meta_tag' => 'name_of_feature',
...
]; And then having a foreach ( $features_to_check as $meta_name => $option_name ) {
if ( (bool) $this->options->get( $option_name ) ) {
$features[] = $meta_name;
}
} |
1 similar comment
I totally agree with this @wordpressfan Pretty simple tho to make it, Having a array such as: $features_to_check = [
'name_displayed_in_meta_tag' => 'name_of_feature',
...
]; And then having a foreach ( $features_to_check as $meta_name => $option_name ) {
if ( (bool) $this->options->get( $option_name ) ) {
$features[] = $meta_name;
}
} |
Description
The Self-host Google Fonts feature should be included in the listed features of the Meta Generator tag
Additional context
Slack: https://wp-media.slack.com/archives/C8L4EE8N9/p1738107801647279
The text was updated successfully, but these errors were encountered: