Я создал простое представление с помощью MetalKit, которое отображает простой треугольник и отлично работает как в предварительном просмотре XCode, так и в симуляторе iPhone с iOS 17.2.
Однако, когда я пытаюсь использовать этот
Код: Выделить всё
ViewКод: Выделить всё
WidgetКод: Выделить всё
The body of the Widget entries' view contains the following unsupported types: PlatformViewRepresentableAdaptor, PlatformViewRepresentableAdaptor
Edit: Thank you for pointing out that iOS is very restrictive when it comes to widget updates. However as I can tell this is not exactly the case for Standby mode when there's nothing else but max 2 widgets on screen. There are some 3rd party standby widgets with continuous, rich and smooth 60fps animations. For example:
Источник: https://stackoverflow.com/questions/779 ... -17-widget
Мобильная версия