()
| 3 | |
| 4 | export default function Home() { |
| 5 | const handleClick = async () => { |
| 6 | let data = { |
| 7 | name: "Shubham", |
| 8 | role: "Coder" |
| 9 | } |
| 10 | let a = await fetch("/api/add", { |
| 11 | method: "POST", headers: { |
| 12 | "Content-Type": "application/json", |
| 13 | }, |
| 14 | body: JSON.stringify(data), |
| 15 | }) |
| 16 | let res = await a.json() |
| 17 | console.log(res) |
| 18 | } |
| 19 | |
| 20 | return ( |
| 21 | <div> |
nothing calls this directly
no outgoing calls
no test coverage detected