Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update tutorial one to reference gatsby astronaut image #9698

Closed
wants to merge 3 commits into from
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file modified docs/tutorial/part-one/04-add-image.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
7 changes: 4 additions & 3 deletions docs/tutorial/part-one/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,16 +79,17 @@ export default () => (

![More changes with hot reloading](03-more-hot-reloading.png)

4. Add an image. (In this case, a random image from Unsplash).
4. Add an image. (In this case, the Gatsby astronaut).

```jsx{7}:title=src/pages/index.js
```jsx{2,8}:title=src/pages/index.js
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you explain to me what this change is please? I haven't seen it before...

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is code snippet line highlighting. It specifies that line 2 and 8 should be highlighted to denote the changes made.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TIL - thank you.

import React from "react"
import gatsbyAstronaut from "../images/gatsby-astronaut.png"

export default () => (
<div style={{ color: `purple` }}>
<h1>Hello Gatsby!</h1>
<p>What a world.</p>
<img src="https://source.unsplash.com/random/400x200" alt="" />
<img src={gatsbyAstronaut} alt="Gatsby astronaut" />
</div>
)
```
Expand Down