-
Open Google fonts
-
Lets suppose I want Roboto, Ubuntu Mono and Oswald fonts for my site. Roboto for paragraphs, Ubuntu Mono for code and Oswald for headings. So Search for the font Roboto
-
Click on google fonts quick use option in front of font which you want to use.
-
Select the styles which you want to use and then click on 'Add to collection'.
After that Roboto is added to collection. -
Now we have to add Ubuntu mono font. For this click on 'Choose'.
Add Ubuntu Mono and Oswald fonts in the same way you added Roboto.
-
To use font in your site. Click on 'use' in the bottom right corner.
-
Copy and paste the code according to your requirement. ie. there are three ways by which you can import fonts through your site, through html, through css and through javascript.
-
If you want to import through html then copy the code under 'standard' tab and put the code in the
<head>
of your HTML document. -
If you want to import through css then copy the code under
@import
tab and put the code in the top of your style sheet -
If you want to import through Javascript then copy the code under 'Javascript' tab and put in the script tag or in javascript file
How to use Google Fonts
H
Published in: Web Development
Originally Published On : May 05, 2016