Can’t fetch a simple API in WidgetKit
I can’t fetch a simple API in WidgetKit. I want to fetch data in a widget from an API: https://jsonplaceholder.typicode.com/posts/1. It doesn’t work. I tried it in Swift apps, JavaScript, and cURL, and it works perfectly everywhere except in the WidgetKit environment. I can’t fetch a simple API in WidgetKit. Specifically, I want to retrieve data from the API: https://jsonplaceholder.typicode.com/posts/1
. However, it doesn’t work in the widget.