{"id":15914730,"url":"https://github.com/snowfirewolf/github-repos-explorer","last_synced_at":"2025-04-03T03:44:37.495Z","repository":{"id":134404790,"uuid":"465298418","full_name":"SnowFireWolf/github-repos-explorer","owner":"SnowFireWolf","description":null,"archived":false,"fork":false,"pushed_at":"2022-03-17T08:14:18.000Z","size":226,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-08T17:46:06.605Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"github-repos-explorer-eight.vercel.app","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/SnowFireWolf.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-03-02T12:34:17.000Z","updated_at":"2022-03-17T08:15:56.000Z","dependencies_parsed_at":null,"dependency_job_id":"4d5b3243-a6ec-4aca-93d9-2c5363d2d537","html_url":"https://github.com/SnowFireWolf/github-repos-explorer","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SnowFireWolf%2Fgithub-repos-explorer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SnowFireWolf%2Fgithub-repos-explorer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SnowFireWolf%2Fgithub-repos-explorer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SnowFireWolf%2Fgithub-repos-explorer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/SnowFireWolf","download_url":"https://codeload.github.com/SnowFireWolf/github-repos-explorer/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246933357,"owners_count":20857052,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-06T17:05:58.112Z","updated_at":"2025-04-03T03:44:37.470Z","avatar_url":"https://github.com/SnowFireWolf.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# github-repos-explorer\n\n2022 Dcard Frontend Intern Home Work\n\n此專案使用 [Next.js](https://nextjs.org/) ，並使用 [swc](https://nextjs.org/docs/advanced-features/compiler)，因此打包與開發的編譯速度會很快。\n\n已使用 Vercel 自動部屬 [https://github-repos-explorer-eight.vercel.app](https://github-repos-explorer-eight.vercel.app) 。\n\n\n\n## 入門開始\n\n### git clone 此專案\n```bash\ngit clone https://github.com/SnowFireWolf/github-repos-explorer.git\n```\n\n### 安裝套件\n```bash\nyarn\n# 或是使用 npm\nnpm install\n```\n\n### 開發模式\n```bash\nyarn dev\n# 或是使用 npm\nnpm run dev\n```\n\n在瀏覽器打開 [http://localhost:3000](http://localhost:3000) ，就可看到網站惹。\n\n### 也可以使用生產模式，先打包在瀏覽\n```bash\nyarn build\n# 或是使用 npm\nnpm run build\n```\n編譯完後使用\n```bash\nyarn start\n# 或是使用 npm\nnpm run start\n```\n\n在瀏覽器打開 [http://localhost:3000](http://localhost:3000) ，一樣就可以看到。\n\n\n\n\n\n## 使用的套件\n* `next`\n透過檔案命名自動處理好 router，編譯程式碼。\n\n* `axios`\n處理 API 串接，自動轉換 JSON 格式。\n\n* `@emotion/styled`\n快速製作復用組件。\n\n\n\n\n\n## 設計架構\n\n### 路徑\n`src/pages` 中的路徑檔案將會被 next 自動轉換。\n\n* src/pages/inxex.tsx =\u003e `/`\n\n  此為首頁，可以在輸入欄位輸入使用者名稱並搜尋儲存庫。\n  \n  畫面：\n  ![Image_2022_03_17__15_34_45__001](https://user-images.githubusercontent.com/14024836/158759441-501e4f4c-cd6b-407f-a544-15af6d9965df.png)\n\n* src/pages/users/[username]\n  * /index.tsx =\u003e `users/{username}/repos`\n\n    列出使用者儲存庫的路徑\n    \n    畫面：\n    ![Image_2022_03_17__15_35_24__001](https://user-images.githubusercontent.com/14024836/158759534-55873ae5-856f-4a1c-bfb1-540c6c8f6a15.png)\n\n  * /[repo].tsx =\u003e `users/{username}/repos/{repo}`\n\n    單一儲存庫資訊\n    \n    畫面：\n    ![Image_2022_03_17__15_36_57__001](https://user-images.githubusercontent.com/14024836/158759742-a4cde75e-5cd6-4cec-9fb3-cbb93cef50d8.png) \n\n### 組件\n\n`src/components/base` 中可能會有復用的基本樣式組件，例如：按鈕、卡片。\n\n### 復用工具\n\n`src/utils`\n\n* request.ts ，使用 axios 包裝，設定會經常使用的網域，用於請求 API。\n\n\n\n\n\n## 例外狀況\n* 找不到使用者\n![Image_2022_03_17__15_38_24__001](https://user-images.githubusercontent.com/14024836/158759974-0c0745c6-9e73-49fc-8c5f-b62068049ce2.png)\n\n* 有使用者，但是沒有任何儲存庫\n![Image_2022_03_17__15_49_27__001](https://user-images.githubusercontent.com/14024836/158761703-11ff3f0e-a03c-4e77-bb03-341a839007c6.png)\n\n* github API 速率限制通知\n![Image_2022_03_17__15_55_53__001](https://user-images.githubusercontent.com/14024836/158762809-bfc4cc38-0dd0-4757-9a13-6a3dda5a8dc2.png)\n\n* 沒有網路連線\n![Image_2022_03_17__15_33_23__001](https://user-images.githubusercontent.com/14024836/158759242-514a33c4-822b-443a-875e-f49d751f499f.png)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsnowfirewolf%2Fgithub-repos-explorer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsnowfirewolf%2Fgithub-repos-explorer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsnowfirewolf%2Fgithub-repos-explorer/lists"}