blob: c9b27e1a7d1df1af6b12f6e5f9658ccdb1daf76e (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
import React, { useState } from 'react';
// import confetti from 'canvas-confetti';
export default function Counter() {
// Declare a new state variable, which we'll call "count"
const [count, setCount] = useState(0);
// console.log(confetti());
return (
<div>
<p>You clicked {count} times</p>
<button onClick={() => setCount(count + 1)}>Click me</button>
</div>
);
}
|