Lecture 3: MVVM and the Swift type system

Поділитися
Вставка
  • Опубліковано 26 гру 2024
  • Lecture 3 of Stanford’s Spring 2021 iteration of its CS193p course (Developing Applications for iOS) starts off with a conceptual overview of the architectural paradigm underlying the development of applications for iOS (known as MVVM) and an explanation of a fundamental component of understanding the Swift programming language: its type system. Then both of these are applied to the Memorize application started in the first two lectures.
    It is impossible to develop applications for iOS using SwiftUI without using the MVVM architecture for organizing your code. This lecture explains what that is and then demonstrates how it works in the demonstration application, Memorize. SwiftUI development happens entirely in the programming language Swift. Swift is unique in its support of most modern language features, including object-oriented programming, functional programming and protocol-oriented programming. Since much of this is new to most Stanford students, this lecture starts the process of explaining how Swift works by covering the basics of its type system, including structs and classes, generics and functions as types. Memorize then moves to the next level, filling out its MVVM architecture by implementing the Model and ViewModel portions of the application while using both generics and functions as types along the way.

КОМЕНТАРІ •