Skip to content
Merged
Changes from all commits
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
14 changes: 8 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -561,15 +561,17 @@
```jsx harmony
<h1>Hello!</h1>
{
messages.length > 0 &&
<h2>
You have {messages.length} unread messages.
</h2>
messages.length > 0 && !isLogin?
<h2>
You have {messages.length} unread messages.
</h2>
:
<h2>
You don't have unread messages.
</h2>
}
```

<!-- TODO: fix this section -->

18. ### What are "key" props and what is the benefit of using them in arrays of elements?

A `key` is a special string attribute you **should** include when creating arrays of elements. *Keys* help React identify which items have changed, are added, or are removed.
Expand Down