swift
This is an old revision of the document!
Swift
Tutorial for beginners: https://developer.apple.com/tutorials/app-dev-training
- Important concept: pass object between views.
struct ScrumsView_Previews: PreviewProvideris just for showing an mock up preview when you coding. It is not a part of the real app.- Add
@Stateat the beginning to declear a single source of truth at the very most parent view. Use$[variable name]to pass it to child view. In child view initialize with@Binding var [variable name]: [variable type]to use that data. - The annotation
environmentObject(_:)means … - Property wrappers is those code started with
@than you add before declearing an variable or object. For example@EnvironmentObject var time: Float
swift.1659886657.txt.gz · Last modified: (external edit)
