Ketty
Explore posts from serversget with params not working
Can someone help me.
i have simple code:
import { Hono } from "hono";
const app = new Hono();
app.get("/", (c) => c.json("list books"));
app.get("/:id", (c) => c.json(
get ${c.req.param("id")}));
export default app;
When try to call api with: curl http://localhost:3000/?id=5 i get response "list books".
Without: app.get("/", (c) => c.json("list books")); i get "404 Not Found"7 replies