refactor: retire redirected course readers without changing legacy URLs
維護者通常 1 天內回覆
還沒有人認領這個 Issue。
評估
- 難度
- 4/5
- 預估耗時
- 3-5 天
- 新手友好度
- 48/100
- Issue 類型
- 重構
- 描述清晰度
- 描述清楚
- 活躍度
- 活躍
- 技術堆疊
- next.js, react, typescript
研究方向
Start by tracing imports from src/app/courses/ and the reader components, then check next.config.ts and the protection helpers to distinguish retired code from shared code. Use e2e/checks.mjs and the reader and redirect browser checks to verify legacy URLs preserve nested paths and query strings, render the dashboard destination, and keep unknown destinations at 404. Done when only unreferenced legacy components are removed, architecture guidance names the canonical reader, and the listed checks pass.
由索引模型根據 Issue 內容生成。
描述
Problem
next.config.ts permanently redirects /courses and /courses/:path* to /dashboard, but the repository retains a second course-reader route tree and its reader components. This makes it harder for contributors to identify the active implementation.
Scope
- Inventory the legacy route/component import graph and confirm which files are unreachable through the supported application routes.
- Remove only duplicate pages/components whose sole consumers belong to that retired tree.
- Preserve the existing permanent redirects, path segments and query strings.
- Keep the active dashboard reader, content safety rules and any shared helpers still used elsewhere.
- Update architecture guidance to identify the canonical reader.
- Treat this as dead-code cleanup; it does not fix an active reading restriction or change the student reading experience.
Starting files
next.config.ts, src/app/courses/, src/app/components/Reader/, src/app/components/Protected/NoCopyWrapper.tsx, src/hooks/useContentProtection.ts, e2e/checks.mjs and docs/architecture.md.
Done when
Tests verify direct legacy requests redirect to the matching dashboard URL, including nested unit paths and query strings. Browser checks confirm the destination renders the expected content and unknown destinations still return 404. Lint, typecheck, unit tests, production build and reader/redirect browser checks pass. Removed components have no remaining consumers.
- 主要語言
- TypeScript
- 星號
- 1
- 分支
- 1
- 平均合併
- 8 小時 58 分鐘
- 30 天內合併 PR
- 37
環境準備
- 提供 Dockerfile 或 Docker Compose 檔案
- 有 Pull Request 範本
- 閱讀貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
procoderji-com/procoderji 的其他 Issue
-
area:frontend bug
難度 2/5 1-3 小時 新手友好度 62/100
procoderji-com/procoderji#104 ·
維護者通常 1 天內回覆
-
enhancement good first issue
難度 2/5 1-3 小時 新手友好度 88/100
procoderji-com/procoderji#36 ·
維護者通常 1 天內回覆
-
enhancement good first issue
難度 1/5 1-3 小時 新手友好度 85/100
procoderji-com/procoderji#35 ·
維護者通常 1 天內回覆
-
enhancement good first issue
難度 1/5 1-3 小時 新手友好度 79/100
procoderji-com/procoderji#34 ·
維護者通常 1 天內回覆
-
enhancement good first issue
難度 1/5 1-3 小時 新手友好度 90/100
procoderji-com/procoderji#33 ·
維護者通常 1 天內回覆
查看 procoderji-com/procoderji 的全部 Issue
相似的 Issue
-
難度 2/5 1-3 小時 新手友好度 72/100
維護者通常 1 天內回覆
-
bug platform-android
難度 2/5 1-3 小時 新手友好度 68/100
Termix-SSH/Mobile#146 · 1 則留言 ·
維護者通常 2 天內回覆
-
bug
難度 2/5 1-3 小時 新手友好度 66/100
devswha/herdr-web-ui#3875 ·
-
難度 1/5 1 小時以內 新手友好度 88/100
-
area: runtime chore cli consistency dependencies developer-experience difficulty: easy discovery documentation enhancement good first issue help wanted hygiene json-output packaging priority: P3 tests version
難度 2/5 1-3 小時 新手友好度 78/100
維護者通常 1 天內回覆