Category: SwiftUI

  • A SwiftUI SiriKit Tutorial

    The previous chapter covered much of the theory associated with integrating Siri into an iOS app. This chapter will review the example Siri messaging extension that is created by Xcode when a new Intents Extension is added to a project. This will not only show a practical implementation of the topics covered in the previous…

  • An Introduction to SwiftUI and SiriKit

    Although Siri has been part of iOS for a number of years, it was not until the introduction of iOS 10 that some of the power of Siri was made available to app developers through SiriKit. Initially limited to particular categories of app, SiriKit has since extended to allow Siri functionality to be built into…

  • Preparing and Submitting an iOS App to the App Store

    After developing an iOS application, the final step is submitting it to Apple’s App Store. Preparing and submitting an application is a multi-step process details of which will be covered in this chapter. Verifying the iOS Distribution Certificate The chapter entitled How to Join the Apple Developer Program covered the steps involved in generating signing…

  • Integrating SwiftUI with UIKit

    Apps developed before the introduction of SwiftUI will have been developed using UIKit and other UIKit-based frameworks included with the iOS SDK. Given the benefits of using SwiftUI for future development, it will be a common requirement to integrate the new SwiftUI app functionality with the existing project code base. Fortunately, this integration can be…

  • Integrating UIViewControllers with SwiftUI

    The previous chapter outlined how to integrate UIView based components into SwiftUI using the UIViewRepresentable protocol. This chapter will focus on the second option for combining SwiftUI and UIKit within an iOS project in the form of UIViewController integration. UIViewControllers and SwiftUI The UIView integration outlined in the previous chapter is useful for integrating either…

  • Integrating UIViews with SwiftUI

    Prior to the introduction of SwiftUI, all iOS apps were developed using UIKit together with a collection of UIKit-based supporting frameworks. Although SwiftUI is provided with a wide selection of components with which to build an app, there are instances where there is no SwiftUI equivalent to options provided by the other frameworks. Given the…

  • Troubleshooting Live Activity Push Notifications

    It can be frustrating when a Live Activity fails to update in response to a push notification, and identifying the cause can initially seem challenging. Part of the problem is that push notifications and Live Activities use systems over which we have little control, such as the APNs, the predictive engine that decides when the…

  • Testing Live Activity Push Notifications

    The previous chapter explained how to add support for push notifications to a Live Activity. Once enabled for push notifications, the Live Activity is ready for testing. Test push notifications can be sent from the CloudKit console or the command line using the curl tool. This chapter will demonstrate both options, including generating the authentication…

  • An iOS 17 Live Activity Push Notifications Tutorial

    Although we have demonstrated that Live Activities can be updated from within an app, a more likely scenario is that the updates will be generated by a remote server and sent to the device. This can be achieved using push notifications. This chapter will introduce push notifications and convert the LiveActivityDemo project from local updates…

  • Adding a Refresh Button to an iOS 17 Live Activity

    The previous chapters introduced Live Activities and created an example project demonstrating Live Activities in action. While testing the example app, it became evident that, regardless of configuration settings, Live Activity updates can be infrequent when the app is in background mode. While we have limited control over when an update will be processed, this…