SwiftUI: How do change chartYvalues?

Viewed 19

This values.Hi! Please tell me how to change these values ? I need a chart that will display price changes , since the spread is small , I want to make a zoom for example from 18.0 to 20.0 , how do I change this? Thank you!

1 Answers

You use the .chartYScale modifier:

Chart {
    //your chart stuff here
}
.chartYScale(domain: 18...20)
Related