Skip to content

Commit

Permalink
[www] Tutorial: Highlight closing tag (#3925)
Browse files Browse the repository at this point in the history
* Highlight closing tag

There are two additions to the code, however only the opening div is highlighted and not its closing tag.

* Made changes suggested by Yisela

@yisela, I changed this! It took a while for me to figure out, which means that most beginners would also have trouble figuring it out, haha. Thanks for noticing and helping Gatsby improve!!!
  • Loading branch information
yisela authored and KyleAMathews committed Feb 16, 2018
1 parent 16e3274 commit b9ceb4c
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions docs/tutorial/part-two/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ Let's make a quick improvement. Many sites have a single column of text centered
in the middle of the page. To create this, add the following styles to the
`<div>` in `src/pages/index.js`.

```jsx{4}
```jsx{4,23}
import React from "react";
export default () =>
Expand Down Expand Up @@ -322,6 +322,7 @@ While we won't cover CSS-in-JS in this initial tutorial, we encourage you to exp
as well as
[Mark Dalgleish's more recent post "A Unified Styling Language"](https://medium.com/seek-blog/a-unified-styling-language-d0c208de2660).


### CSS Modules

Let's explore **CSS Modules**.
Expand Down Expand Up @@ -422,8 +423,8 @@ Paste the following into the file:
}
```

Now import that file into the `about-css-modules.js` page we created earlier.
Also log the resulting import so we can see what the processed file looks like.
Now import that file into the `about-css-modules.js` page we created earlier, by adding the following on lines 2 and 3.
(The `console.log(styles)` code logs the resulting import so we can see what the processed file looks like).

```javascript
import styles from "./about-css-modules.module.css";
Expand Down Expand Up @@ -453,6 +454,7 @@ Modify `about-css-modules.js` so it looks like the following:
```jsx{6-17,23-30}
import React from "react";
import styles from "./about-css-modules.module.css";
console.log(styles);
import Container from "../components/container";
Expand Down

0 comments on commit b9ceb4c

Please sign in to comment.