SwiftUI environment makes it easy to pass data down the view hierarchy. I have a post that covers how to work with it, including reading and setting values, defining custom keys, using it with Observable.
If you’re working with #SwiftUI, you might find it helpful: https://nilcoalescing.com/blog/SwiftUIEnvironment/
If you’re working with #SwiftUI, you might find it helpful: https://nilcoalescing.com/blog/SwiftUIEnvironment/
Comments