From 6240fed5683433af9bfe626639cccc9bdf0076f2 Mon Sep 17 00:00:00 2001 From: Jake Boone Date: Fri, 10 Jun 2022 08:17:33 -0700 Subject: [PATCH] docs: fix incomplete sentences in useref.md (#4731) --- beta/src/pages/apis/useref.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/beta/src/pages/apis/useref.md b/beta/src/pages/apis/useref.md index 7b6e215e..4bd400a5 100644 --- a/beta/src/pages/apis/useref.md +++ b/beta/src/pages/apis/useref.md @@ -63,9 +63,9 @@ function handleStopClick() { By using a ref, you ensure that: -- You can **store information** between re-renders. (Unlike regular variables, which reset on every render.) -- Changing it **does not trigger a re-render**. (Unlike state variables, which trigger a re-render.) -- The **information is local** to each copy of your component. (Unlike the variables outside, which are shared.) +- You can **store information** between re-renders (unlike regular variables, which reset on every render). +- Changing it **does not trigger a re-render** (unlike state variables, which trigger a re-render). +- The **information is local** to each copy of your component (unlike the variables outside, which are shared). Changing a ref does not trigger a re-render, so refs are not appropriate for storing information that you want to display on the screen. Use state for that instead. Read more about [choosing between `useRef` and `useState`](/learn/referencing-values-with-refs#differences-between-refs-and-state).