Переглядів 35,410
In this video we will discuss the basics of inits and enums in SwiftUI views. Inits, formerly 'initializers', are functions that run when a view is created and are used to customize the view. We will first walk through the default inits that come standard in SwiftUI and then we will learn how to make our own custom init functions. After, we will briefly look at making custom enums (or enumerations) to make our Swift code organized and efficient.
We will cover:
(1) What is an init() in SwiftUI?
(2) How to customize init() in SwiftUI
(3) How to use enum in SwiftUI
Next video: • How to use ForEach loo...
Last video: • How to use Spacer in S...