skip to Main Content

How to use @Viewbuilder and return view in swiftUi? – Ios swift

I have overlay with below code .overlay(abcViewModel.isError ? AnyView(DialogBoxOneButton(accessibilityID: "dialogboxes", dialogboxType: .error, dialogboxTitle: "title", dialogboxBody: "body", dialogboxFirstButtonTitle: "title", dialogboxFirstButtonCallback: { action() abcViewModel.isError = false }, isDialogboxFirstButtonClicked: .constant(true))) : AnyView(EmptyView())) I am trying to avoid use of Anyview and did below…

VIEW QUESTION
Back To Top
Search