From 8d9b002130db2e18062d2d4fefc6ffb50a04c6b8 Mon Sep 17 00:00:00 2001 From: Gavin Elster Date: Wed, 22 May 2019 18:34:04 +0800 Subject: [PATCH] Fix typo (#2021) * Fix typo Adds a missing word * Update content/docs/hooks-faq.md Co-Authored-By: Alexey Pyltsyn --- content/docs/hooks-faq.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/content/docs/hooks-faq.md b/content/docs/hooks-faq.md index a7583966..422073a9 100644 --- a/content/docs/hooks-faq.md +++ b/content/docs/hooks-faq.md @@ -694,7 +694,7 @@ function Counter() { In more complex cases (such as if one state depends on another state), try moving the state update logic outside the effect with the [`useReducer` Hook](/docs/hooks-reference.html#usereducer). [This article](https://adamrackis.dev/state-and-use-reducer/) offers an example of how you can do this. **The identity of the `dispatch` function from `useReducer` is always stable** — even if the reducer function is declared inside the component and reads its props. -As a last resort, if you want to something like `this` in a class, you can [use a ref](/docs/hooks-faq.html#is-there-something-like-instance-variables) to hold a mutable variable. Then you can write and read to it. For example: +As a last resort, if you want something like `this` in a class, you can [use a ref](/docs/hooks-faq.html#is-there-something-like-instance-variables) to hold a mutable variable. Then you can write and read to it. For example: ```js{2-6,10-11,16} function Example(props) {