더북(TheBook)

components/AddTodo.js

import React, {useState} from 'react';
import {
  View,
  StyleSheet,
  TextInput,
  Image,
  TouchableOpacity,
} from 'react-native';

function AddTodo() {
  const [text, setText] = useState('');

  return (
    <View style={styles.block}>
      <TextInput
        placeholder="할일을 입력하세요."
        style={styles.input}
        value={text}
        onChangeText={setText}
      />
    <TouchableOpacity activeOpacity={0.5}>
        <View style={styles.buttonStyle}>
          <Image
          source={require('../assets/icons/add_white/add_white.png')}
          />
        </View>
    </TouchableOpacity>
    </View>
  );
}

(...)
신간 소식 구독하기
뉴스레터에 가입하시고 이메일로 신간 소식을 받아 보세요.