From 44e9fa59366b14da67a30274f018e495859cd8b7 Mon Sep 17 00:00:00 2001 From: Vadim Demedes Date: Mon, 23 Sep 2019 00:06:23 -0700 Subject: [PATCH] Switch useLayoutEffect with useEffect --- src/hooks/use-input.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/hooks/use-input.js b/src/hooks/use-input.js index 5620b0af8..913c7b350 100644 --- a/src/hooks/use-input.js +++ b/src/hooks/use-input.js @@ -1,10 +1,10 @@ -import {useLayoutEffect, useContext} from 'react'; +import {useEffect, useContext} from 'react'; import {StdinContext} from '..'; export default inputHandler => { const {stdin, setRawMode} = useContext(StdinContext); - useLayoutEffect(() => { + useEffect(() => { setRawMode(true); return () => { @@ -12,7 +12,7 @@ export default inputHandler => { }; }, [setRawMode]); - useLayoutEffect(() => { + useEffect(() => { const handleData = data => { let input = String(data); const key = {