Skip to contents

Downloads and installs a font family from Google Fonts using the official API

Usage

install_google_font(
  font_name,
  api_key = "AIzaSyDOr3jWLtl4IP08yNaddV61_40f0YByPHo"
)

Arguments

font_name

Character string of the font name (e.g. "Dancing Script")

api_key

Google Fonts API key. Defaults to a hard-coded key that has very generous usage limits. If you need your own key, you can get one from the Google Cloud Console.

Value

Logical indicating whether the font was successfully installed