Skip to content

Commit 7337f1a

Browse files
ghost23timdorr
authored andcommitted
Update api.md (#710)
Injecting the state into a component will rerender the component on every state change instead of every action. Also see issue #709
1 parent 9c62d60 commit 7337f1a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/api.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ export default connect(null, actionCreators)(TodoApp)
151151

152152
##### Inject `dispatch` and every field in the global state
153153

154-
>Don’t do this! It kills any performance optimizations because `TodoApp` will rerender after every action.
154+
>Don’t do this! It kills any performance optimizations because `TodoApp` will rerender after every state change.
155155
>It’s better to have more granular `connect()` on several components in your view hierarchy that each only
156156
>listen to a relevant slice of the state.
157157

0 commit comments

Comments
 (0)