From 3855a587a081fea73590e2e53670554f0ed74d6e Mon Sep 17 00:00:00 2001 From: Imbus Date: Fri, 15 Dec 2023 01:19:54 +0100 Subject: [PATCH] Boilerplate for NewPostContainer --- src/components/NewPostContainer.tsx | 39 +++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 src/components/NewPostContainer.tsx diff --git a/src/components/NewPostContainer.tsx b/src/components/NewPostContainer.tsx new file mode 100644 index 0000000..3257858 --- /dev/null +++ b/src/components/NewPostContainer.tsx @@ -0,0 +1,39 @@ +import React from "react"; +import { View, Text, TextInput, Button } from "react-native"; +import { style } from "../util/style"; +import { createPost, NewPost } from "../util/api"; + +export function NewPostContainer(): JSX.Element { + const [currentInput, setCurrentInput] = React.useState(""); + const [currentInputError, setCurrentInputError] = React.useState(""); + + return ( + + { + setCurrentInput(text); + setCurrentInputError(""); + }} + value={currentInput} + /> +