• Resolved kghugo2000

    (@kghugo2000)


    Dear developers,

    It is possible to stop oceanwp from requesting italic font from Google? I want to do this as I don’t use italic font at all and I want to improve performance.

    Thank you for reading and your help.

    The page I need help with: [log in to see the link]

Viewing 4 replies - 1 through 4 (of 4 total)
  • twgerber

    (@twgerber)

    I added this code to my child theme php file:

    function myprefix_google_fonts( $array ) {
    return array( ‘Lato’, ‘Roboto’, ‘poppins’, ‘Karla’ );
    }
    add_filter( ‘ocean_google_fonts_array’, ‘myprefix_google_fonts’ );

    It only loads those fonts now….

    I think 🙂

    Amit Singh

    (@apprimit)

    Hello,

    Try to add the below code to the functions.php file of the oceanwp child theme and check it works or not –

    add_filter( 'ocean_google_font_enqueue_italics', '__return_false');

    Thread Starter kghugo2000

    (@kghugo2000)

    Thank you so much! It is working perfectly!

    Amit Singh

    (@apprimit)

    You’re welcome!

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Avoid loading italic font’ is closed to new replies.