We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent bb3c3b9 commit e5e7a35Copy full SHA for e5e7a35
src/pages/Home.js
@@ -4,10 +4,11 @@ import Question from "../ui/Question/Question";
4
import QuestionsHeader from "../ui/QuestionsHeader/QuestionsHeader";
5
import createPersistedState from "use-persisted-state";
6
const useItemsState = createPersistedState("items");
7
+const useHideState = createPersistedState("hideCompleted");
8
9
const Home = () => {
10
const [items, setItems] = useItemsState([]);
- const [hideCompleted, setHideCompleted] = useState(false);
11
+ const [hideCompleted, setHideCompleted] = useHideState(false);
12
13
const handleItems = questionId => {
14
if (items && items.find(item => item == questionId)) {
0 commit comments