![](https://cdn-images-1.medium.com/fit/t/1600/480/1*VGvuY1ViIdR7xAtXBliy1Q.jpeg)
找出 JSONDecoder 的 decode 錯誤
利用 JSONDecoder,我們可以很方便地將 API 回傳的 JSON 資料轉成遵從 Decodable 的自訂型別,例如以下結合 Dog API,抓取可愛小狗圖片的例子。
These were the top 10 stories published by 彼得潘的 Swift iOS App 開發問題解答集 in January of 2019. You can also dive into daily archives for January of 2019 by using the calendar at the top of this page.