Post

Replies

Boosts

Views

Activity

Comment on Binding with optional Value causes runtime crash
There is not issue with nameBinding or with viewModel.name, with both variants you have a crash. Your suggested approach with .constant(name) means that this Binding won't be changed in ChildView, but it supposes to be changed, because it has text field, so .constant(name) is not correct.
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
May ’23