Created
April 27, 2021 07:58
-
-
Save jaunesarmiento/9819682761040a213291b40ccf9d5435 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function App() { | |
// ... rest of our code here | |
return ( | |
<div className="app"> | |
<div className="header"> | |
<AmplifySignOut /> | |
</div> | |
<div className="container"> | |
<div className="messages"> | |
<div className="messages-scroller"> | |
{messages.map((message) => ( | |
<div | |
key={message.id} | |
className={message.author === 'Dave' ? 'message me' : 'message'}>{message.body}</div> | |
))} | |
</div> | |
</div> | |
<div className="chat-bar"> | |
<form onSubmit={handleSubmit}> | |
<input | |
type="text" | |
name="message" | |
placeholder="Type your message here..." | |
onChange={handleChange} | |
value={messageBody} /> | |
</form> | |
</div> | |
</div> | |
</div> | |
); | |
} | |
export default withAuthenticator(App); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment