In a very basic app (iOS), I am finding that a view with this...
---
struct IdeaDetail: View {
var idea: Idea
var body: some View {
ScrollView() {
VStack(alignment: .leading) {
Text(verbatim: idea.name)
.font(.title)
Text(idea.text)
.lineLimit(nil)
.font(.body)
}
}
}
}
---
is truncating the text (idea.text). There appears to be no pattern to when it is truncating it. I want it to display the entire text (which is often many lines) but it is cutting off the last few lines in almost every case, even when it doesn't have to scroll. Putting this inside a scrolling element in UIKit hasn't been a problem for me in the past and I'm quite curious what's going on. I've checked the boundaries that are generated on the frame and they seem to move around quite a bit depending on the content of idea.text but they don't seem to want to grow to fit the entire contents of the string.
idea.name and idea.text are both String.
Thanks!