import React, {useState} from 'react';
const [count,setCount] = useState(5);
const incrementcount = () => {
setCount(count+1);
}
return (
<div>
<button onClick={incrementcount}> + </button>
<span> {count} </span>
<button> - </button>
</div>
)
}
export default App;
when I use 'count++' instead of 'count+1',it shows an error...why so?