Enhanced Development Features in Xcode 15

Darshan Gujarati
Simform Engineering
8 min readJul 13, 2023

Discover the new features in Xcode 15 unveiled at this year’s WWDC

Xcode, the integrated development environment (IDE) for Apple platforms, continues to evolve with each new release.

Apple’s latest iteration, Xcode 15, brings several exciting enhancements aimed at improving the development workflow, making coding easier, and fostering an enjoyable app-building experience.

In this blog post, we will delve into the key areas where Apple has focused its efforts to empower developers: Editing, Navigating, Sharing, Testing, Debugging, and Distributing Apps.

Gif by Giphy

1. Editing

Xcode 15 brings a range of powerful editing features that aim to enhance the coding experience for developers. One notable improvement is the advanced code completion functionality, which provides better suggestions for modifiers in SwiftUI.

Advanced Code Completion:

  • Code completion is an essential feature in any modern IDE, and Xcode 15 takes it to the next level with enhanced suggestions for modifiers in SwiftUI.
  • When writing SwiftUI code, Xcode’s code completion now offers more accurate and context-aware suggestions for modifiers based on the current code context. It considers the properties and types used in the code and provides relevant suggestions that align with the SwiftUI syntax.
Now Xcode gives the most suitable suggestions
  • Furthermore, Xcode 15’s code completion prioritizes suggestions based on usage frequency.
  • Xcode 15’s code completion prioritizes suggesting frequently used modifiers, making the coding process more efficient by offering relevant suggestions based on your previous usage.
Xcode knows the current context and gives unused, most relevant modifiers in the suggestions

Code Completed Asset Catalog:

  • Xcode 15’s code-completed asset catalog allows developers to treat images or colors as symbols.
  • Instead of using hardcoded image names as strings, developers can now refer to images and colors by their symbol names, offering improved code readability and maintainability.
Here we have added the image as an asset in the asset catalog
  • With code completion, developers can easily discover and select the desired image symbol from the asset catalog. This feature simplifies working with images and custom colors in code, making it more intuitive and reducing the likelihood of errors.
You can use the code completed asset using the name of the asset

String Catalog:

  • With Xcode 15’s String Catalog, developers can now consolidate all localized strings into a single location. This centralized approach simplifies the management of localization, making it easier to review, update, and maintain translations.

You can create String Catalog by selecting Edit ->Convert to String Catalog and choosing files as per requirement.

All new string catalog interface to see localization in one place
  • Additionally, Xcode 15’s String Catalog enables quick searching and filtering of strings based on specific criteria, facilitating efficient localization management.
  • Developers can easily identify untranslated or incomplete strings, making it easier to focus on the areas that require attention.

Documentation Preview:

In Xcode 15, you can preview the documentation in real-time at Editor>Assistant and then Documentation Preview in the jump bar.

Editor>Assistant>Documentation Preview in the jump bar to see the preview
  • With Xcode 15, developers can create customized documentation. This feature allows for the inclusion of various elements such as detailed explanations, code snippets, symbols, usage examples, specific techniques, and even screenshots.
Customizable documentation preview with more detailed description options

Preview:

  • In Xcode 15, the preview feature is now available for both UIKit and AppKit frameworks, expanding its usefulness beyond SwiftUI. This means developers can leverage previews to design and iterate on user interfaces across different frameworks.
  • Additionally, Xcode 15 allows for the utilization of multiple previews simultaneously, enabling developers to preview and compare various UI states or scenarios side by side.
  • To differentiate between multiple previews, developers have the option to assign placeholders, making it easier to identify and distinguish between different preview cases.
Using Preview API for ViewController in UIKit

2. Navigating

With each version, Apple introduces new capabilities and enhancements to help developers navigate their projects with ease. These improvements often include performance optimizations, new navigation options, and streamlined workflows.

Bookmark:

  • Xcode 15 introduces “Bookmarks”, a toolbar feature that lets users manage and organize their codebase with ease.
Bookmark option available for any line of code to get easier and faster access to the code line
  • Users can add bookmarks to specific code lines. These bookmarks can be filtered and sorted based on different criteria, allowing users to quickly locate and access important code areas.
In Bookmark Navigator you can see all the bookmarks and their descriptions
Bookmark has a status that marks areas that require further attention
  • Whether it’s a specific function, a block of code, or even a single line, users can mark it as a bookmark for easy reference in the future. This flexibility enables developers to quickly jump to important sections of code or mark areas that require further attention or revision.
  • By adding bookmarks at specific lines, developers can streamline their workflow, enhance code navigation, and stay organized while working on their projects.

3. Sharing

In Xcode 15, sharing code snippets and collaborating with team members has become more convenient and streamlined.

Gif by Giphy

Source Control Navigator:

  • In Xcode, the integration with git’s staging features has been enhanced, allowing for a seamless and non-modal approach to committing code.
  • The source control navigator is now used for performing commits, providing a unified interface.
  • One notable improvement is the ability to differentiate between staged and unstaged changes within a file. This makes it easier to review and manage code modifications.
The source control navigator shows the list of newly added and modified files
  • Within the source control navigator, users can address any errors or conflicts in their changes. They can view the specific modifications made, show the differences between the current and previous versions, and even discard unwanted changes.
  • By clicking on a changed line, a scrolling view displays the specific line in question, allowing users to focus on the relevant code.
  • Additionally, users can expand the view to see more surrounding code if needed.

Overall, these enhancements in Xcode simplify the process of committing code by providing a non-modal interface, improved visibility of changes, and convenient options for reviewing, resolving, and discarding modifications.

4. Testing

In Xcode 15, testing receives significant enhancements, starting with an updated test navigator.

  • The test navigator has been completely rewritten in Swift, providing improved performance and reliability.
  • One notable feature is the ability to use filters to obtain test results based on their type, allowing developers to focus on specific categories or subsets of tests.
  • Xcode 15 introduces enhanced test result analysis graphics that offer insights and pattern-based analysis. This enables developers to better understand test outcomes, identify recurring patterns or issues, and improve overall test suite performance and quality.
  • These testing improvements make the testing experience in Xcode 15 more streamlined and efficient.
  • The rewritten test navigator and enhanced analysis graphics empower developers to navigate and analyze test results effectively, providing valuable insights to drive continuous improvement in their testing processes.

5. Debugging

Xcode 15 brings significant improvements to the debugging experience, starting with the integration of OSLogs.

OSLog is a powerful tool for capturing runtime information, offering a structured and customizable logging mechanism that keeps log output organized.

Image from FranchiseONE.de
  • In Xcode 15, by default, metadata fields are hidden, allowing for cleaner log presentation.
  • Additionally, the background color of the logs indicates the severity, making it easier to identify critical messages when searching through long streams of log output.
  • With OSLogs integration, developers have the flexibility to choose which fields they want to see in the logs, tailoring the information displayed to their specific needs.
  • Filtering options enable users to narrow down the logs based on specific types or criteria, improving the efficiency of log analysis.
  • One standout feature is the ability to jump directly to the line of code that generated a particular log message. This feature provides valuable context and expedites the debugging process by allowing developers to quickly locate and address issues within their code.

Overall, the debugging improvements in Xcode 15 significantly enhance the debugging workflow, empowering developers to diagnose and resolve issues more efficiently.

6. Distributing App

In Xcode 15, distributing apps with Xcode Cloud becomes even more convenient.

  • Xcode Cloud automatically handles essential tasks such as build versioning, app signing, and distribution profile management.
  • Additionally, Xcode Cloud now offers two new features to streamline the distribution process.
Gif by Giphy
  • Firstly, Xcode Cloud introduces improved TestFlight test details. It allows developers to include test notes directly alongside their source code, providing a more organized and centralized approach to documenting and tracking test information.
  • Secondly, Xcode Cloud simplifies the notarization process for Mac apps. By adding a notarization post-action to the workflow, Xcode Cloud takes care of the entire notarization and stapling process automatically.

Once completed, the app is ready to be downloaded, ensuring compliance with Apple’s notarization requirements.

Furthermore, Xcode 15 enhances the security of XCFrameworks by introducing signature verification. Authors can digitally sign the framework, and developers can verify the signature slice to identify the producer and the most recent signer.

This verification process adds an extra layer of trust and authenticity when working with XCFrameworks.

Overall, these enhancements in Xcode Cloud simplify the app distribution process, improve test management capabilities, automate notarization for Mac apps, and enhance the security of XCFrameworks, providing a more streamlined and efficient development and distribution workflow.

Conclusion

Xcode 15 offers a comprehensive set of enhancements that empower developers to write code more efficiently, collaborate effectively, test their apps more comprehensively, debug easily, and distribute them seamlessly.

Gif by Giphy

These improvements contribute to a smoother and more productive development experience, enabling developers to create exceptional apps for Apple platforms.

If there are any additional features of Xcode 15 that we may have missed or overlooked, please feel free to add a comment below. Thanks!

Meanwhile, follow Simform Engineering for more such insights and updates.

--

--