Last active
March 29, 2020 21:06
-
-
Save atkinsio/8dbbfd3fab2f7c4cff13858fa9b3f065 to your computer and use it in GitHub Desktop.
[React State] #react #js
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
import React, { useState } from 'react'; | |
const App = () => { | |
//... | |
const [state, setState] = useState(''); | |
//... | |
setState('xyz); | |
}; | |
export default App; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment