import React, { useState } from "react";
const Counter = () => {
// Here we use the useState -->
const [count, setCount] = useState(0);
// Here we make the function of the Count with setCount
const onClick = () => {
setCount(count + 1);
};
return (
<div>
<p>You Clicked {count} On The Button</p>
<button onClick={onClick}>Click Me></button>
</div>
);
};
export default Counter;