Builds Google Fonts URL from family name. Extra weights are given in the
...
parameters. Languages can be specified in languages
and must one or
more of the language codes as given by google_language_codes()
.
Arguments
- family
Font family
- ...
Font weights to include, example "400", "400i"
- languages
Font languages to include (dependent on the font.) See
google_language_codes()
.
Examples
google_font("Josefin Sans", "400", "400i", "600i", "700")
#> Family: Josefin Sans
#> Weights: 400,400i,600i,700
#> URL: https://fonts.googleapis.com/css?family=Josefin+Sans:400,400i,600i,700&display=swap
google_font("Josefin Sans", languages = c("latin-ext", "vietnamese"))
#> Family: Josefin Sans
#> Langs: latin-ext,vietnamese
#> URL: https://fonts.googleapis.com/css?family=Josefin+Sans&subset=latin-ext,vietnamese&display=swap