I’m continuing with the Managing State and Life Cycle section of the Apple SwiftUI Tutorial.
Section 4: Add a State Object
Purpose: Learn about State Object
This sections was pretty small and introduced the concept of “Source of Truth”.
![There can be only one! Image of code with source of truth](https://cdn.uploads.micro.blog/661/2020/d3a19f2aad.png)
At this point, I got a little side track with trying to get an understanding of how it all comes together and getting the above picture.
Section 6: Extract the Meeting Footer
I’m not a fan on the syntax for closures and views. Defining a closure in the view means that I have to specify it when I call the view doesn’t make since to me.
![closure_error.png Error when using a view without specifying something](https://cdn.uploads.micro.blog/661/2020/5315521561.png)
I guess it’s part of the language. You can’t have a view that has values that aren’t defined.
Section 7: Trigger Sound with AVFoundation
Purpose: Lear about audio feed back
Right away, I liked this part of the tutorial because it starts showing me how to use different resources.