Google Web Fonts Loader is a JavaScript library developed by Google that allows you to dynamically load any of the free web fonts developed by Google. Using the Google Web Fonts Loader library we can use multiple different web font providers.
The documentation and source code of the Web Font Loader JavaScript library is available as an open source project on GitHub at http://github.com/typekit/webfontloader.
The library was co-developed by Google and Typekit. You can find more detailed information about this library at https://developers.google.com/fonts/docs/webfont_loader.
One option for using this library would be to include a link for the file hosted on Google servers. The following code sample shows how simple it is.
<!DOCTYPE html> <html> <head> <title>Web Font Loader Demo</title> <script src="http://ajax.googleapis.com/ajax/libs/webfont/1.4.7/webfont.js"></script> <script> WebFont.load({ google: { families: ['Tangerine', 'Droid Serif'] } }); </script> <style> body { font-family: 'Tangerine'; font-size: 52px; } </style> </head> <body> We Love Programming! </body> </html>
The following video clip goes over this code sample, shows its execution and explains it step by step.
You can find more training resources for learning how to use this library in my free courses website at http://abelski.lifemichael.com.