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

Use core script registration using 'defer' attribute #22

Open
carstingaxion opened this issue Aug 18, 2023 · 0 comments
Open

Use core script registration using 'defer' attribute #22

carstingaxion opened this issue Aug 18, 2023 · 0 comments
Labels
bug Something isn't working PART WP core WordPress core related

Comments

@carstingaxion
Copy link
Member

// Add defer attribute to script tag
// @todo Use core script registration using 'defer' attribute
// @see  https://make.wordpress.org/core/2023/07/14/registering-scripts-with-async-and-defer-attributes-in-wordpress-6-3/
// Was before: add_filter( 'script_loader_tag', __NAMESPACE__ . '\\defer_frontend_js', 0, 3 ); // !
add_filter( 'Figuren_Theater\Theming\Defer_Async_Loader\scripts_to_defer', __NAMESPACE__ . '\\defer_frontend_js', 0, 3 );

add_filter( 'embed_privacy_opt_out_headline', '__return_false' );
// if we set the shortcode attr 'subline' to empty values,
// empty html-tags are still rendered
add_filter( 'embed_privacy_opt_out_subline', '__return_false' );

@carstingaxion carstingaxion added bug Something isn't working PART WP core WordPress core related labels Aug 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working PART WP core WordPress core related
Projects
None yet
Development

No branches or pull requests

1 participant