I'm writing view that should contain multiline text, I use scroll view to scroll it, but it also wraps my text. Modifiers like .lineLimit(nil) doesn't work.
var body: some View {
ScrollView{
Text(lesson.text)
}
}
So it is screenshots without and with scroll view.
var body: some View {
ScrollView{
Text(lesson.text)
.fixedSize(horizontal: false, vertical: true)
}
}
should solve the problem.
This is default in iOS 13.1 and above.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With