Skip to content

Commit 78f78a6

Browse files
authored
Update tutorial.md (#3922)
1 parent cf86b00 commit 78f78a6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

content/tutorial/tutorial.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -454,7 +454,7 @@ When a Square is clicked, the `onClick` function provided by the Board is called
454454
1. The `onClick` prop on the built-in DOM `<button>` component tells React to set up a click event listener.
455455
2. When the button is clicked, React will call the `onClick` event handler that is defined in Square's `render()` method.
456456
3. This event handler calls `this.props.onClick()`. The Square's `onClick` prop was specified by the Board.
457-
4. Since the Board passed `onClick={() => this.handleClick(i)}` to Square, the Square calls `this.handleClick(i)` when clicked.
457+
4. Since the Board passed `onClick={() => this.handleClick(i)}` to Square, the Square calls the Board's `handleClick(i)` when clicked.
458458
5. We have not defined the `handleClick()` method yet, so our code crashes. If you click a square now, you should see a red error screen saying something like "this.handleClick is not a function".
459459

460460
>Note

0 commit comments

Comments
 (0)