Skip to content

Commit 0589024

Browse files
authored
Update error-boundaries.md
1 parent 09dbffb commit 0589024

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

content/docs/error-boundaries.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ Error boundaries preserve the declarative nature of React, and behave as you wou
141141

142142
Error boundaries **do not** catch errors inside event handlers.
143143

144-
React can recover from errors in event handlers because, unlike the render method and lifecycle hooks, they don't happen during rendering. So if they throw, React still knows what to display on the screen.
144+
React doesn't need error boundaries to recover from errors in event handlers. Unlike the render method and lifecycle hooks, the event handlers don't happen during rendering. So if they throw, React still knows what to display on the screen.
145145

146146
If you need to catch an error inside event handler, use the regular JavaScript `try` / `catch` statement:
147147

0 commit comments

Comments
 (0)