Browse Source

missing word: of (#5669)

main
Laube 2 years ago
committed by GitHub
parent
commit
9f929d3195
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      beta/src/content/learn/responding-to-events.md

2
beta/src/content/learn/responding-to-events.md

@ -454,7 +454,7 @@ function Button({ onClick, children }) {
}
```
You could add more code to this handler before calling the parent `onClick` event handler, too. This pattern provides an *alternative* to propagation. It lets the child component handle the event, while also letting the parent component specify some additional behavior. Unlike propagation, it's not automatic. But the benefit of this pattern is that you can clearly follow the whole chain code that executes as a result of some event.
You could add more code to this handler before calling the parent `onClick` event handler, too. This pattern provides an *alternative* to propagation. It lets the child component handle the event, while also letting the parent component specify some additional behavior. Unlike propagation, it's not automatic. But the benefit of this pattern is that you can clearly follow the whole chain of code that executes as a result of some event.
If you rely on propagation and it's difficult to trace which handlers execute and why, try this approach instead.

Loading…
Cancel
Save