beforeEach ์ฝ๋๊ฐ ์๋ํ์ง ์์ต๋๋ค.
์ ๋ ์ฐ์ต ์ฐจ์์์ ํจ์ํ ์ปดํฌ๋ํธ๋ก ์์ฑํ๋๋ฐ ์ ๋ ์๋์ ์ด์์ด ์์ด์์ ํน์๋ ๋์์ด ๋ ๊นํด์ ์์ค ์ฝ๋ ์ฌ๋ ค๋๋ฆฝ๋๋ค. import React,{Component, useState} from 'react'; import { Button, TextInput, View } from 'react-native'; const AddToDo = (props) => { const [text, setText] = useState(''); const onChangeText = (text) => { setText(text) } const onPress = () => { const { onAdded } = props; onAdded(text) } return ( ) }; export default AddToDo