Post

Replies

Boosts

Views

Activity

Comment on scenePhase not work consistently on watchOS
Thanks for the response. I meant the following: I minimised the app by clicking the digital crown (rotatory wheel on watch). Then I reopened it again, but the items weren’t loaded. In other scenarios they’ve been loaded. How to see the logs when I’m running the app on my watch? I didn’t find immediate solution how to connect it with XCode for debugging.
Sep ’25
Comment on Closure | Error when referring static variable
Is there a possibility to define the string variable once and refer it in #Predicate and view's properties?
Topic: Programming Languages SubTopic: Swift Tags:
Replies
Boosts
Views
Activity
Jun ’24
Comment on Closure | Error when referring static variable
I tried but I still get an error. Can you show an example for usage in Query and in view's properties?
Topic: Programming Languages SubTopic: Swift Tags:
Replies
Boosts
Views
Activity
Jun ’24
Comment on SwiftUI view is not updated properly
I've provided simplified working example in the reply below. No I didn't try it as I'd like to have this in this view for better overview of those multiple views and separation of concerns. First example was not totally correct, sorry. See new example.
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
Jul ’24
Comment on SwiftUI view is not updated properly
Indeed, init is called multiple times. See new working example in reply below. I'll try your suggestion.
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
Jul ’24
Comment on scenePhase not work consistently on watchOS
Thanks for the response. I meant the following: I minimised the app by clicking the digital crown (rotatory wheel on watch). Then I reopened it again, but the items weren’t loaded. In other scenarios they’ve been loaded. How to see the logs when I’m running the app on my watch? I didn’t find immediate solution how to connect it with XCode for debugging.
Replies
Boosts
Views
Activity
Sep ’25
Comment on scenePhase not work consistently on watchOS
Solved it. I misinterpreted scenePhase . If the app is in foreground I thought it would be also "active". To see whether app is in foreground (active or inactive) I only need to check whether scenePhase isn't background.
Replies
Boosts
Views
Activity
Sep ’25
Comment on scenePhase not work consistently on watchOS
Thank you!
Replies
Boosts
Views
Activity
Sep ’25