Skip to content

Commit e0f137a

Browse files
authored
docs(using-react-redux/static-types): fix typos (#1609)
1 parent e0097f5 commit e0f137a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

website/versioned_docs/version-7.1/using-react-redux/static-types.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ export type RootState = ReturnType<typeof rootReducer>
3030
// {posts: PostsState, comments: CommentsState, users: UsersState}
3131
```
3232
33-
### Typing the useSelector hook
33+
### Typing the `useSelector` hook
3434
3535
When writing selector functions for use with `useSelector`, you should explicitly define the type of the `state` parameter. TS should be able to then infer the return type of the selector, which will be reused as the return type of the `useSelector` hook:
3636
@@ -46,7 +46,7 @@ const selectIsOn = (state: RootState) => state.isOn
4646
const isOn = useSelector(selectIsOn)
4747
```
4848

49-
If you want to avoid repeating the `state` type declaration, you can define a typed `useSelect` hook using a helper type exported by `@types/react-redux`:
49+
If you want to avoid repeating the `state` type declaration, you can define a typed `useSelector` hook using a helper type exported by `@types/react-redux`:
5050

5151
```ts
5252
// reducer.ts

0 commit comments

Comments
 (0)