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

[www] Tutorial: Highlight closing tag #3925

Merged
merged 2 commits into from Feb 16, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
8 changes: 5 additions & 3 deletions docs/tutorial/part-two/index.md
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}
Copy link
Contributor

Choose a reason for hiding this comment

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

I'm only seeing one line of addition to the code (line 4). What other addition did you see?

Also, what would be the purpose of highlighting the closing ? (which seems like it's on line 25, although I could be wrong since I'm not a developer!)

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