Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Custom font
add_action( 'wp_enqueue_scripts', 'custom_google_fonts' );
function custom_google_fonts() {
wp_enqueue_style( 'custom-font', "//fonts.googleapis.com/css?family=Roboto:400,300,100,500");
}
To include multiple fonts at once, add the | separator, like so
wp_enqueue_style( 'custom-font', "//fonts.googleapis.com/css?family=Roboto:400,300,100,500|Roboto+Slab:400,300,100,500");
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.