Skip to content

Commit

Permalink
docs: Match egghead.io video instructions (#34315)
Browse files Browse the repository at this point in the history
  • Loading branch information
fagiani authored Dec 28, 2021
1 parent 5fa836e commit bd3524e
Showing 1 changed file with 19 additions and 2 deletions.
21 changes: 19 additions & 2 deletions docs/tutorial/building-a-theme.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,12 @@ In the `package.json` file in `gatsby-theme-events`, add the following:
"name": "gatsby-theme-events",
"version": "1.0.0",
"main": "index.js",
"license": "MIT"
"license": "MIT",
"scripts": {
"build": "gatsby build",
"develop": "gatsby develop",
"clean": "gatsby clean"
}
}
```

Expand Down Expand Up @@ -129,14 +134,20 @@ If you run `yarn workspaces info`, you'll be able to verify that the site is usi

### Add peer dependencies to `gatsby-theme-events`

Targeting the `gatsby-theme-events` workspace, install `gatsby`, `react`, and `react-dom` as peer dependencies:
Targeting the `gatsby-theme-events` workspace, install `gatsby`, `react`, and `react-dom` as peer and development dependencies:

```shell
yarn workspace gatsby-theme-events add -P gatsby react react-dom
```

> 💡 The `-P` flag is shorthand for installing peer dependencies.
```shell
yarn workspace gatsby-theme-events add -D gatsby react react-dom
```

> 💡 The `-D` flag is shorthand for installing development dependencies.
The `gatsby-theme-events/package.json` file should now include the following:

```json:title=gatsby-theme-events/package.json
Expand All @@ -145,6 +156,12 @@ The `gatsby-theme-events/package.json` file should now include the following:
"gatsby": "^3.0.0",
"react": "^17.0.0",
"react-dom": "^17.0.0"
},
{
"devDependencies": {
"gatsby": "^3.0.0",
"react": "^17.0.0",
"react-dom": "^17.0.0"
}
}
```
Expand Down

0 comments on commit bd3524e

Please sign in to comment.