()
| 2 | |
| 3 | |
| 4 | function App(){ |
| 5 | |
| 6 | const [count,setCount] = useState([10,20,30]); |
| 7 | |
| 8 | function handleChange(){ |
| 9 | setCount([...count,40]); |
| 10 | } |
| 11 | |
| 12 | return ( |
| 13 | <> |
| 14 | <p>This is the counter for react App</p> |
| 15 | <h1>Counter:{count}</h1> |
| 16 | <button onClick={handleChange}>Increment</button> |
| 17 | {/* <button onClick={()=>setCount(count-1)}>Decrement</button> */} |
| 18 | </> |
| 19 | ) |
| 20 | } |
| 21 | |
| 22 | export default App; |
nothing calls this directly
no outgoing calls
no test coverage detected