Elementor speed
Wed Jan 05 2022 07:59:06 GMT+0000 (Coordinated Universal Time)
Saved by
@mastaklance
/**
* Remove google fonts from Elementor
*/
add_filter( 'elementor/frontend/print_google_fonts', '__return_false' );
/**
* Remove Font Awesome from Elementor
*/
add_action( 'elementor/frontend/after_register_styles',function() {
foreach( [ 'solid', 'regular', 'brands' ] as $style ) {
wp_deregister_style( 'elementor-icons-fa-' . $style );
}
}, 20 );
/**
* Remove Eicons from Elementor
*/
add_action( 'wp_enqueue_scripts', 'js_remove_default_stylesheet', 20 );
function js_remove_default_stylesheet() {
// Don't remove it in the backend
if ( is_admin() || current_user_can( 'manage_options' ) ) {
return;
}
wp_deregister_style( 'elementor-icons' );
}
content_copyCOPY
Comments