I'm trying to arrange a text horizontally, like a description, but I'm ending with an ugly thing. I'll post the code below, maybe someone have a clue how to fix this. Thanks !
VStack {
HStack {
ForEach(meniu!.ingredients) { men in
let ingredient = syncViewModel.fetchByIdIngredients(ingredientId: men.ingredient)
if ingredient != nil {
Text("\(ingredient?.name ?? "" ), ")
.foregroundColor(.colorGrayDark)
} else {
EmptyView()
}
}
}
}
CodePudding user response: