diff --git a/src/mocks/handlers/recipeHandlers.ts b/src/mocks/handlers/recipeHandlers.ts index 99dfa10d..88edfacd 100644 --- a/src/mocks/handlers/recipeHandlers.ts +++ b/src/mocks/handlers/recipeHandlers.ts @@ -7,12 +7,6 @@ import mockRecipes from '../data/recipes.json'; export const recipeHandlers = [ rest.get('/api/recipes/:recipeId', (req, res, ctx) => { - // const { mockSessionId } = req.cookies; - - // if (!mockSessionId) { - // return res(ctx.status(401)); - // } - return res(ctx.status(200), ctx.json(recipeDetail), ctx.delay(1000)); }), diff --git a/src/router/index.tsx b/src/router/index.tsx index c948441f..9b41c576 100644 --- a/src/router/index.tsx +++ b/src/router/index.tsx @@ -53,15 +53,6 @@ const router = createBrowserRouter([ return { Component: MemberRecipeBookmarkPage }; }, }, - { - path: `${PATH.RECIPE}/:recipeId`, - async lazy() { - const { RecipeDetailPage } = await import( - /* webpackChunkName: "RecipeDetailPage" */ '@/pages/RecipeDetailPage/RecipeDetailPage' - ); - return { Component: RecipeDetailPage }; - }, - }, ], }, /** 레이아웃이 있는 페이지 */ @@ -141,6 +132,16 @@ const router = createBrowserRouter([ }, ], }, + /** 레시피 상세 페이지 */ + { + path: `${PATH.RECIPE}/:recipeId`, + async lazy() { + const { RecipeDetailPage } = await import( + /* webpackChunkName: "RecipeDetailPage" */ '@/pages/RecipeDetailPage/RecipeDetailPage' + ); + return { Component: RecipeDetailPage }; + }, + }, /** 검색 페이지 */ { path: '/',