Created
May 17, 2020 18:00
-
-
Save jsmanifest/5bd6db89cb6685ac347477a151ae670a to your computer and use it in GitHub Desktop.
This file contains hidden or 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
import React from 'react' | |
import './styles.css' | |
function MyInput() { | |
const [value, setValue] = React.useState('') | |
function onChange(e) { | |
setValue(e.target.value) | |
} | |
return ( | |
<div> | |
<input type='text' value={value} onChange={onChange} /> | |
</div> | |
) | |
} | |
export default MyInput |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment