Skip to content
This repository has been archived by the owner on Nov 11, 2020. It is now read-only.

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
tbaustin committed Feb 10, 2020
1 parent 657ef59 commit b562fae
Showing 1 changed file with 4 additions and 43 deletions.
47 changes: 4 additions & 43 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,45 +1,6 @@
# gatsby-plugin-prefetch-google-fonts
# legacy-gatsby-plugin-prefetch-google-fonts

A Gatsby plugin to download and prefetch [Google Fonts](https://fonts.google.com/). Can increase performance as opposed to loading webfonts from Google's external stylesheet.
**DO NOT USE**

## Installation

With npm:

```bash
npm install --save gatsby-plugin-prefetch-google-fonts
```

Or with Yarn:

```bash
yarn add gatsby-plugin-prefetch-google-fonts
```

## Usage

In your `gatsby-config.js` file, load in the plugin along with which web fonts to load.

```javascript
module.exports = {
plugins: [
{
resolve: `gatsby-plugin-prefetch-google-fonts`,
options: {
fonts: [
{
family: `Oswald`,
subsets: [`latin`],
},
{
family: `Open Sans`,
variants: [`400`, `700`]
},
],
},
}
]
}
```

For a list of all available font family options, consult the [google-fonts-plugin readme](https://github.com/SirPole/google-fonts-plugin).
Now part of [escalade](https://github.com/escaladesports/escalade-internal/tree/master/packages/gatsby-plugin-prefetch-google-fonts
) monorepo.

0 comments on commit b562fae

Please sign in to comment.