Your Second iOS & SwiftUI App

Nov 4 2021 · Swift 5.5, iOS 15, Xcode 13

Part 1: List View Fundamentals

03. Models & Views

Episode complete

Play next episode

Next
About this episode

Leave a rating/review

See forum comments
Cinema mode Mark complete Download course materials
Previous episode: 02. List Rows Next episode: 04. SF Symbols

Get immediate access to this and 4,000+ other videos and books.

Take your career further with a Kodeco Personal Plan. With unlimited access to over 40+ books and 4,000+ professional videos in a single subscription, it's simply the best investment you can make in your development career.

Learn more Already a subscriber? Sign in.

Heads up... You’re accessing parts of this content for free, with some sections shown as obfuscated text.

Heads up... You’re accessing parts of this content for free, with some sections shown as obfuscated text.

Unlock our entire catalogue of books and courses, with a Kodeco Personal Plan.

Unlock now

We’ve got some simple but solid starter UI in place, and we’re ready to put some data in there. So, let’s take a minute to think about the kind of data we want to keep in this app.

struct Book {

}
let title: String
let author: String
  let author: String

  init(title: String, author: String) {
    <#statements#>
  }
}
init(title: String = "Title", author: String = "Author") {
  init(title: String = "Title", author: String = "Author") {
    self.title = title
    self.author = author
  }
import SwiftUI

extension Book {
  
}
extension Book {
  struct Image: View {
    var body: some View {
      Image(systemName: "book")
        .resizable()
        .scaledToFit()
        .frame(width: 80, height: 80)
        .font(Font.title.weight(.light))
        .foregroundColor(.secondary)
    }
  }
}
SwiftUI.Image(systemName: "book")
Book.Image()
struct Book_Previews {

}
struct Book_Previews: PreviewProvider {
struct Book_Previews: PreviewProvider {
  static var previews: some View {

  }
}
  static var previews: some View {
    Book.Image()
  }