Created
April 1, 2019 07:05
-
-
Save marvinjude/1a996bbf0fc2312cb1ca2adf3375dcb4 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
| function Example(){ | |
| //Scenerio A | |
| let[name, setUser] = useState('') | |
| let[age, setAge] = useState('') | |
| let[school, setSchool] = useState('') | |
| let[height, setHeight] = useState('') | |
| //Scenerio B | |
| let [data, setData] = useState({ | |
| name: "Agboola Jude", | |
| age: "40", | |
| school: "New Orleans High", | |
| height: "49M" | |
| //... | |
| //... | |
| ///... | |
| //.. | |
| //.. | |
| }) | |
| return( | |
| //use state here | |
| ) | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment