I have a DisclosureGroup(isExpanded: ..) inside a SwiftUI view that shows checkbox options with a button that when clicked shows an Alert for the user to accept/store their selection. The SwiftUI view is inside a tableView cell using cell.contentConfiguration = UIHostingConfiguration {..}
- The Alert action from the SwiftUI view has to call a function to store the user’s choice that is located in the Tableview controller
- it will also have to delete the current row updating the tableview UI immediately.
The data on the SwiftUI View are sent by TableViewController using a class ShowContent: ObservableObject {.. through @Published properties.
- Question:
How can I make a trigger action to update the UIKit UI coming from the SwiftUI View Alert to make the tableView be updated asap?