Top Features in iOS 12 Every iOS Developer Needs to Know

DZone 's Guide to

Top Features in iOS 12 Every iOS Developer Needs to Know

iOS 12 has been here a bit now, so let's examine twelve of the features this platform comes with that every iOS developer should know.

· Web Dev Zone ·
Free Resource

The latest iOS version has a rich set of features in terms of performance and user experience and comes with huge enhancements in performance, security and privacy. Whilst considering these features for users, we also need to consider what this release means to every iOS developer and QA engineer. In this post, we will explore some major development and testing considerations for Apple's operating system.

1. Xcode 10

Apple announced Xcode 10 with a full list of the new features for iOS developers. The most noticeable feature of Xcode 10 is a dark mode with macOS Mojave. With Xcode 10, developers can write code in dark mode. Xcode 10 obviously shipped with all the iOS 12 simulators and can build an app on the newly launched device. Other important features launched with Xcode 10 are multi-line editing, code snippets for other languages like Ruby, Python, etc. Last year, Apple announced integrated support for GitHub within Xcode. With Xcode 10, we will have support for GitLab and Bitbucket as well. You can check all the new features in the Xcode 10 release notes. Xcode 10 shipped with Swift 4.2 but we can use Swift toolchains to switch between the Swift versions.

2. New Build System

With Xcode 10, we will have a new build system enabled by default. The new build system is designed for faster Swift builds and optimizing the speed of iOS apps. All apps developed for iOS 12 will be using the new build system. As a developer, we need to make sure that existing apps still work with new build systems; if not, we have to make them compatible or switch to the old build system from the Xcode Files ->Project/Workspace Setting option.

3. XCTest/XCUITest and Code Coverage

Apple is revamping the tools, technologies, and practices for testing iOS apps. As usual, there are some great features added with Xcode 10 and iOS 12. The key improvements are as follows:

Parallel Testing

Support for parallel testing has been taken to the next level. Now we can officially run XCTest or Xcode UI Test in parallel by having a number of clones running in a simulator. The native tool, xcodebuild, also has an option to run them in parallel. We can enable parallel testing by updating the scheme and in the Test action, we can select "Options" against a test bundle to choose parallelization option, and more. The details on parallel testing can be found here.

Randomizing Tests

Previously, XCTest used to run in alphabetical order but with Xcode 10 onwards we can run tests in a random order. This will be a useful feature to find any dependencies that exist between tests.


Apple announced this native tool to generate code coverage for Swift. This reduces the pain of using third-party tools to display Xcode code coverage reports in a nice format. The details of xccov and latest XCTest features can be found here.

4. Swift

Xcode 10 comes up with Swift 4.2. There is one thing we need to note about Xcode 10: it is the last release supporting Swift 3. If your app is still using Swift 3 then it's worth thinking out the migration to the latest version of Swift.

5. Siri Shortcut

One of the major features announced with iOS 12 was Siri Shortcuts. The Siri Shortcuts can be used to expose your app features to Siri so that Siri can suggest some of the features of your apps to users. This enables a new way of interacting with your users from iOS as well as from watchOS. Now that developers can use custom intent Siri Shortcuts for iOS 12 apps, Apple has provided resources in terms of WWDC videos and example apps to help developers get started with Siri Shortcuts. Siri Shortcuts is a new way of communicating with your existing users, so get ready to implement this features into your apps.

6. ARKit 2.0

Arkit is a great framework which allows developers to write augmented reality apps for iOS. With iOS 12, developers can use ARKit 2.0 for face tracking and 3D object detection. 

7. Machine Learning

Apple announced the Core ML framework last year to support machine learning in iOS apps. However, in order to create machine learning models, the developer has to rely on third-party frameworks like TensonFlow or IBM Watson. This year, with iOS 12, we can use the Create ML framework for generating machine learning models with Swift and within Xcode. Now developers can implement end-to-end machine learning flows using Swift and Xcode 10. This will reduce the burden on developers to learn third-party machine learning frameworks and algorithms.

8. CarPlay

Apple announced a customisable framework for CarPlay, which means that, with iOS 12, developers can create apps for CarPlay with smooth animations and better communication capabilities. The biggest news for developers is that you can use Google Maps on iOS CarPlay.

9. Photos and Images

Apple has improved the Photos experience a lot in iOS 12. There are some cool features like personalised Photo, Photo searcher, etc. The iOS apps involved in the business of printing photos can take advantage of these features. Apple has improved the portrait segmentation API and Depth API to interact with images in a new way. By using this new API, developers are able to build apps with various photo effects.

10. Notifications

The user notifications have been improved drastically since iOS 10, but with iOS 12 we can add more controls to remote and local notifications. Now it's possible to add buttons, switches, and custom views to the notifications using UserNotificationsUI API.

11. Performance

Apple seems to have made a significant improvement in the performance in all areas including faster a keyboard display and app launching. It's worth checking existing apps on iOS 12 to see how the app launch improvement hasn't affected launch screen images or text. It's great news for the developer that iOS 12 will give them performance improvements for free.

12. Privacy and Security

Apple has packed loads of security and privacy features into iOS 12. The key security and privacy features include a built-in password manager, easy two-factor authentication, and blocked access to USB if locked for more than an hour. Apple has put in all the security features in a single document. With iOS 12, developers can improve the user experience of existing apps while logging in or onboarding using the Password AutoFill API. When considering this security feature, developers needs to be aware of upgrades that might lead to terrible consequences like dropping passwords using AirDrop, which can leak sensitive data to hackers.

ios 12, mobile application development, swift, web dev, xcode

Published at DZone with permission of Shashikant Jagtap , DZone MVB. See the original article here.

Opinions expressed by DZone contributors are their own.

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}