diff --git a/src/App.jsx b/src/App.jsx index 5d62758..7562728 100644 --- a/src/App.jsx +++ b/src/App.jsx @@ -1,17 +1,10 @@ -import { useState } from "react"; -import reactLogo from "./assets/react.svg"; -import viteLogo from "/vite.svg"; import "./App.css"; +import Input from "./components/Input" function App() { - const [count, setCount] = useState(0); - const name = "류승찬"; - - return ( - <> - 화이팅 - > + return( + ); } -export default App; +export default App; \ No newline at end of file diff --git a/src/components/Input.jsx b/src/components/Input.jsx new file mode 100644 index 0000000..d68f765 --- /dev/null +++ b/src/components/Input.jsx @@ -0,0 +1,24 @@ +import { useState,useRef } from "react"; +import Log from "./Log" + + + +function Input() { + const [inp, setInp] = useState(''); + + const inpRef = useRef(null); + + const focusInp = () => { + inpRef.current.focus() + } + return ( +
입력한 내용 : {inp}
+목록: {texts.join(', ')}
+