@State vs @Binding in SwiftUI
A parent view owns an isOn Boolean. A child toggle view must read and change it. How should the child declare it?
Discussion 0
Join free to post in the discussion.
Related questions
- StatelessWidget or StatefulWidgetMobile App Developer
- Layering views in SwiftUIMobile App Developer
- Making a composable reusableMobile App Developer
- Counter jumps back to zeroMobile App Developer
- Closing a sheet from inside itMobile App Developer
- ForEach over a custom structMobile App Developer
- Using a SwiftUI view in UIKitMobile App Developer
- Previewing a SwiftUI viewMobile App Developer