Feature fetch bookings
還沒有人認領這個 Issue。
評估
- 難度
- 2/5
- 預估耗時
- 1-3 小時
- 新手友好度
- 58/100
- Issue 類型
- 功能
- 描述清晰度
- 描述清楚
- 活躍度
- 停滯
- 技術堆疊
- javascript, react
- 領域
- frontend
研究方向
從 元件開始,將其目前的資料來源與 data/fakeBookings.json 進行比較。依照 issue 中關於 useEffect、fetch() 和 https://cyf-react.glitch.me 的指引操作,然後確認 customers 資料仍會在表格中正確顯示,且重新整理後首次 render 時的 console 訊息只出現一次。
由索引模型根據 Issue 內容生成。
描述
16. Load bookings remotely
Instructions:
Instead of getting the existing bookings from the file data/fakeBookings.json, we will get and load the bookings from a remote API. In the <Bookings /> component, use the React function useEffect to console.log() some text only when the page first renders on the screen. Verify that when you refresh the page, the text appears once in the console. Then, in the useEffect function, use the fetch() function to get data from https://cyf-react.glitch.me.
Try to pair or mob on this feature.
Hints:
- Replace
FakeBookingsin the bookings state and initialise it with[](because we haven't fetched any results yet!) - After calling the
fetch()function, use.then()to handle the response. Try looking at your Pokemon app that you worked on in class for an example - When the response comes back, use
setBookingsto update the results
Test:
- Verify the customers data are still displayed correctly in the table.
- 主要語言
- JavaScript
- 星號
- 1
- 分支
- 28
- PR 合併指標
- 30 天內沒有已合併 PR
環境準備
- 沒有 Dockerfile 或 Docker Compose 檔案
- 有 Pull Request 範本
- 沒有貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
CodeYourFuture/React-Module-Project 的其他 Issue
-
♟️ Dependent ticket 🏕 Priority Mandatory 🐇 Size Small 📅 Week 3 📅 Week 4
難度 2/5 1-3 小時 新手友好度 65/100
-
🏕 Priority Mandatory 🐂 Size Medium 📅 Week 4 🧩 Feature
難度 2/5 1-3 小時 新手友好度 65/100
-
🐂 Size Medium 📅 Week 3 🧩 Feature
難度 2/5 1-3 小時 新手友好度 65/100
-
🏝️ Priority Stretch 🐂 Size Medium 📅 Week 2 🧩 Feature
難度 2/5 1-3 小時 新手友好度 65/100
-
🏕 Priority Mandatory 🐇 Size Small 📅 Week 2 🧩 Feature
難度 1/5 1 小時以內 新手友好度 68/100
查看 CodeYourFuture/React-Module-Project 的全部 Issue
相似的 Issue
-
難度 2/5 1-3 小時 新手友好度 68/100
smansfield635-create/smansfield635-create.github.io#5818 · 4 則留言 ·
維護者通常 1 天內回覆
-
documentation
難度 2/5 1-3 小時 新手友好度 85/100
danjdewhurst/story-skills#538 ·
維護者通常 1 天內回覆
-
good first issue
難度 1/5 1-3 小時 新手友好度 88/100
anoopcodehack/DevBoard#589 ·
維護者通常 2 天內回覆
-
難度 2/5 1 小時以內 新手友好度 85/100
capricorn86/happy-dom#2474 ·
維護者通常 2 天內回覆
-
難度 1/5 1 小時以內 新手友好度 95/100
vigetlabs/mega-menu-block#30 ·
維護者通常 2 天內回覆