sudheerj / reactjs-interview-questions

List of top 500 ReactJS Interview Questions & Answers....Coding exercise questions are coming soon!!
38.89k stars 9.24k forks source link

Incorrect code sample for Q 335 #270

Closed devrutul closed 11 months ago

devrutul commented 12 months ago

For functional component, setCountry is used, it should be setMessage

`function App() { const [message, setMessage] = useState("This is a functional component"); const updateMessage = () => { setCountry("Updating the functional component"); }; return (

{message}

); }`

by the way nice work👍

sudheerj commented 11 months ago

Fixed. Thank for your words.