Integrating Google Gemini AI with Swift and SwiftUI
At the upcoming WWDC, Apple is expected to announce an on-device large language model (LLM). The next version of the iOS SDK will likely make it easier for developers to integrate AI features into their apps. While we await...
Using Xcode Previews in UIKit Development
When SwiftUI was first released, one of the great features that piqued my interest was the instant preview function. This feature empowers developers to preview the user interface of any view within Xcode, entirely bypassing the...
Understanding @FocusState, @FocusedValue and @FocusedObject
In any user interface, focus plays a crucial role in determining which element receives the next input. SwiftUI provides a powerful set of tools and view modifiers that allow you to control and manage focus in your apps. By using...
How to Build a Barcode Generator Using SwiftUI
I recently received a question from a friend regarding barcode generation using Swift. The CoreImage framework provides convenient built-in APIs for creating various types of barcodes, including QR codes. In this tutorial,...
Using SwiftData with Preview in SwiftUI
In the earlier tutorial, I have walked you through the basics of SwiftData, a new framework introduced in iOS 17 as a replacement for Core Data. If you have followed that tutorial, you should now be familiar with using SwiftData...
Customizing Toolbar and Navigation Bar in SwiftUI
The Toolbar API has been available for a considerable period, having been introduced with the release of iOS 14. It was a valuable addition to the SwiftUI framework, enabling developers to incorporate menu items in the navigation...
Using SymbolEffect to Animate SF Symbols in iOS 17
When it comes to designing visually appealing and intuitive user interfaces in iOS development, SF Symbols are an invaluable asset. It offers a comprehensive library of over 5,000 customizable icons, designed specifically for iOS...
Creating Tooltips with the new TipKit Framework
It’s always important to make your app as intuitive as possible. However, for some features, it may be helpful to provide extra information to teach users how to use them effectively. That’s where TipKit comes in....
Creating Advanced Animations with KeyframeAnimator in SwiftUI
In addition to the PhaseAnimator, SwiftUI introduced the KeyframeAnimator in iOS 17, allowing developers to create advanced animations using keyframes. In this tutorial, we will delve into the KeyframeAnimator and learn how to...
Using PhaseAnimator to Create Dynamic Multi-Step Animations
SwiftUI already streamlines the creation of view animations. One example is the matchedGeometryEffect modifier, which enables developers to define the appearance of two views. The modifier calculates the disparities between the...