Skip to content
  • Sponsor WaifuAPI/documentation

  • Notifications You must be signed in to change notification settings
  • Fork 2
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit c845822

Browse files
authoredOct 28, 2023
Fixed broken codes causing issue
1 parent 6914d08 commit c845822

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed
 

‎components/counters.tsx

+24
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
// Example from https://beta.reactjs.org/learn
2+
3+
import { useState } from 'react'
4+
import styles from './counters.module.css'
5+
6+
function MyButton() {
7+
const [count, setCount] = useState(0)
8+
9+
function handleClick() {
10+
setCount(count + 1)
11+
}
12+
13+
return (
14+
<div>
15+
<button onClick={handleClick} className={styles.counter}>
16+
Clicked {count} times
17+
</button>
18+
</div>
19+
)
20+
}
21+
22+
export default function MyApp() {
23+
return <MyButton />
24+
}

0 commit comments

Comments
 (0)
Failed to load comments.