diff --git a/server/controllers/ourTeam.js b/server/controllers/team.js similarity index 100% rename from server/controllers/ourTeam.js rename to server/controllers/team.js diff --git a/server/routes/team.js b/server/routes/team.js new file mode 100644 index 0000000..3c2651a --- /dev/null +++ b/server/routes/team.js @@ -0,0 +1,7 @@ +import express from "express" +const router = express.Router() +import { getTeamMembers } from "../controllers/team.js" + +router.get("/team", getTeamMembers); + +export { router } \ No newline at end of file diff --git a/server/server.js b/server/server.js index 197f626..07dc733 100644 --- a/server/server.js +++ b/server/server.js @@ -12,6 +12,7 @@ import { router as fridgeRoutes } from "./routes/fridge.js" import { router as postRoutes } from "./routes/posts.js" import { router as profileRoutes } from "./routes/profile.js" import { router as mainRoutes } from "./routes/main.js" +import { router as teamRoutes } from "./routes/team.js" import dotenv from "dotenv" import path from "path" @@ -81,6 +82,7 @@ app.use("/", mainRoutes) app.use("/fridge", fridgeRoutes) app.use("/post", postRoutes) app.use("/profile", profileRoutes) +app.use("/team", teamRoutes) // Serve React App