https://developer.apple.com/documentation/swiftui/state-and-data-flow

As shown in Figure 1 , we have Text stlyle rendering is based on some condition if selected == true we will make the background color of Text red.


In previous part we covered the advanced topic of compositional layout . In this part we will be working with supplementary view . Now that we are comfortable with the base implementation, this part of the series will focus on the Supplementary Items and Decorations that we can use in a Compositional Layout and the way to implement them.

CollectionView manages three basic view class types: Your cells, the things you interact with to express your model objects; it also represents supplementary items and decoration items. …


In previous part we covered the basic of compositional layout . In this part we will see more advanced topic.

Compositional Layout with Custom Model

As shown in Figure 1 we created collection view cell called topApp in App Store


Apple introduced Collection View in iOS 6, In previous blogs we created layout using ios 6 API. In iOS 13 , they are supercharged with the addition of Compositional layout

Compositional layout →, a type of collection view layout that’s composable (from small bits of layout), flexible, and fast, letting you build any kind of visual arrangement for your content. It’s declarative api. In ios 13 app store and share sheet re-architecture using compositional layout, With Compositional layout you get RTL support for free and no code for paging behaviour for RTL language

In this part we created a grid…


https://www.raywenderlich.com/5304228-ios-animation-tutorial-getting-started

In this part we will see How we can customize push and pop animation of navigation controller and further more we will create real life reusable View using custom modal transition (Bottom Sheet)

In previous part we built custom presenting view controllers , you can build custom transitions to push and pop new view controllers.” as well. If you read previous part , you’ll find that custom navigation controller transitions feel quite similar to presenting view controllers.” It is highly recommended to read previous part

As shown in Gif we we are doing standard push and pop animation here


https://www.raywenderlich.com/5304228-ios-animation-tutorial-getting-started

In this part we will see how we can create custom Modal View controller transition animation

Customizing Modal Transition Animations

Transition animations provide visual feedback about changes to your app’s interface. UIKit provides a set of standard transition styles to use when presenting view controllers, and you can supplement the standard transitions with custom transitions of your own.

As shown in Figure 1 we have two View controller (let’s name it as VC1 and VC2 respectively ) when user tap on Red view of VC1 we will redirect user to VC2


It is mandatory to see previous part, otherwise you don’t get anything. In previous part we create swift package and used it in other app. In this blog we will see how we can edit out package

Editing Packages

  1. Both local and remote package are editable , We will see later what I mean by remote package are editable
  2. Package added as dependency of project lock for editing because they are auto managed by Xcode,

As you can see in Figure 1 , our App is pointing to private Home package repo through SPM remotely


In this blog we will see how we can create our own swift package and published it as private and how can we use it on some other project

Create A Swift Package

Packages are a great way to share code both in your workspace with your team or with a wider open source community

As shown in Figure 1 Go to File → New → Swift Package → Home


https://swift.org/package-manager/

In this blog we will see how we can integrate public swift package in our fresh app, or app that uses cocoapod and how we can replace cocoapod dependency with SPM

Swift Package Manager(SPM)

  1. The Swift Package Manager is a tool for managing the distribution of Swift code
  2. It’s a dependency manager like cocoa-pod or Carthage
  3. It requires Xcode 11(Swift 5.1) or higher /
  4. It helps you to manage third-party libraries and split up your project into the different module or even distribute your own package to others
  5. SPM is part of the Swift toolchain
  6. Here I talked about the benefits of using…

https://www.raywenderlich.com/5304228-ios-animation-tutorial-getting-started

In a previous blog we talked about how we can animate auto-layout constraint and saw different animation API. In this blog we will animate view properties to do some standard animation we already know, On previous blog we were calling layoutIfNeeded since we were mostly aimating autolayout, here we will animate view properties

Fade In / Fade Out

As shown in Gif 1 we created fade in and fade out animation using one view and by changing UIVIew animatable property which is alpha.

Ali Akhtar

Senior iOS Engineer | HungerStation | Delivery Hero

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store