SwiftUI 读书笔记之 01《Pro iPhone Development with SwiftUI: Design and Manage Top Quality Apps》

读书笔记《Pro iPhone Development with SwiftUI: Design and Manage Top Quality Apps》

书籍目录

Chapter 1:Organizing Code1

  • Using the // MARK: Comment4
  • Using Files and Folders7
  • Use Code Snippets11
  • Creating Custom Code Snippets13
  • Editing and Deleting Custom Code Snippets15
  • Use View Modifiers16
  • Summary18

Chapter 2:Debugging Code19

  • Simple Debugging Techniques22
  • Using the Xcode Debugger26
  • Using Breakpoints27
  • Stepping Through Code28
  • Managing Breakpoints31
  • Using Symbolic Breakpoints32
  • Using Conditional Breakpoints35
  • Summary37

Chapter 3:Understanding Closures39

  • Closures with Multiple Parameters42
  • Understanding Value Capturing43
  • Using Closures like Data44
  • Using Trailing Closures46
  • Passing Parameters to a Trailing Closure
  • Passing Parameters and Returning a Value from a Trailing Closure

Chapter 4:Multithreaded Programming Using Grand Central Dispatch

  • Understanding Threads54
  • Using Grand Central Dispatch60
  • Using Dispatch Groups67
  • Summary72

Chapter 5:Understanding Concurrency

  • Concurrency with Async/Await74
  • Using Concurrency with User Interfaces

Chapter 6:Understanding Data Persistence

  • Storing Preferences in UserDefaults86
  • Reading and Writing to Files
  • Using Core Data
  • Creating a Data Model File
  • Adding Core Data to an Existing Project

Chapter 7:Sharing Data Between Structures

  • Sharing Data with Bindings117
  • Sharing Data with StateObject and ObservedObject124
  • Sharing Data with EnvironmentObject

Chapter 8:Translating with Localization

  • Creating a Localization File138
  • Defining Multiple Previews145
  • Using a LocalizableStringKey148
  • Using String Interpolation with Localizable Strings
  • Formatting Numbers and Dates155
  • Using Pseudolanguages

Chapter 9:Adding Search to an App165

  • Adding a Search Bar to a List View166
  • Changing the Placeholder Text in the Search Bar169
  • Making the Search Bar Visible Initially170
  • Adding Suggestions to the Search Bar172
    Summary175

Chapter 10:Detecting Motion and Orientation177

  • Understanding Core Motion177
  • Detecting Acceleration178
  • Detecting Rotation with the Gyroscope184
  • Detecting Magnetic Fields188
  • Detecting Device Motion Data192
    Summary195

Chapter 11:Using Location and Maps197

  • Using MapKit197
  • Defining Accuracy198
  • Defining a Distance Filter199
  • Requesting a Location200
    -Retrieving Location Data200
  • Requesting Authorization201
  • Adding a Map Marker205
  • Adding a Map Pin208
  • Adding a Map Annotation210
  • Summary

精品教程推荐


加入我们一起学习SwiftUI

QQ:3365059189
SwiftUI技术交流QQ群:518696470
教程网站:www.openswiftui.com

发表回复