Skip to content

Added Button and Input Field#12

Open
Lsimmons98 wants to merge 1 commit intolearn-co-curriculum:masterfrom
Lsimmons98:workingBranch
Open

Added Button and Input Field#12
Lsimmons98 wants to merge 1 commit intolearn-co-curriculum:masterfrom
Lsimmons98:workingBranch

Conversation

@Lsimmons98
Copy link
Copy Markdown

Added button and input field to components with relevant event handlers.

Comment on lines +5 to +8
<button
onFocus={ () => console.log('Good!') }
onBlur={ () => console.log('Hey! Eyes on me!') }
>
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be awesome to move these functions in their own functions outside of the return:

Suggested change
<button
onFocus={ () => console.log('Good!') }
onBlur={ () => console.log('Hey! Eyes on me!') }
>
const handleFocus = () => console.log('Good!')
const handleBlur = () => console.log('Hey! Eyes on me!')
<button
onFocus={handleFocus}
onBlur={handleBlur}
>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants