Created
June 1, 2020 18:05
-
-
Save kauemurakami/c21c617d4fd576f5be07bb993a2d4094 to your computer and use it in GitHub Desktop.
arquivo de rotas
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { Router } from "https://deno.land/x/attain/mod.ts"; | |
import { getUsers, getUser, updateUser, addUser, deleteUser } from "../controllers/client_controller.ts" | |
const clientsRouter = new Router() | |
clientsRouter.get("/", getUsers ) | |
clientsRouter.get("/:id", getUser) | |
clientsRouter.put("/:id", updateUser); | |
clientsRouter.delete("/:id", deleteUser); | |
clientsRouter.post("/", addUser) | |
export default clientsRouter |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment