4 ms·
Yeah I can't find a clear way to do this from Swift and APIs apple exposes. I can be very wrong though and just didn't dig hard enough
by awaseem 2y ago
Yeah I can't find a clear way to do this from Swift and APIs apple exposes. I can be very wrong though and just didn't dig hard enough
- filoleg 2y agoAh, you were trying to do it through Swift/within an actual app, thanks for clarifying. I think you are right, I couldn’t find a way to directly set status from within Swift, but there is a somewhat janky workaround I thought of. You should be able to have Shortcut hooks within your app (i.e., once the shortcut is triggered, it triggers an action within your app; or, inversed, have your app trigger a shortcut), and then have an official companion Shortcut for your users they can install with a single click. There might be other valid approaches, but they all seem to involve Shortcuts in some way. However, it is definitely a suboptimal approach, compared to just doing it all within the app (which I couldnt find a way to do either).
- awaseem 2y agoMaybe they'll add it in the next wwdc!