How can I use strokeBorder for trimed Shapes in SwiftUI?

Viewed 159

I have difficulty to use strokeBorder after trim in SwiftUI, how can do this?

Circle()
  .trim(from: 0, to: 0.5)
  .strokeBorder(Color.red, style: StrokeStyle(lineWidth: 50.0, lineCap: .round, lineJoin: .round))

Error:

Value of type 'some Shape' has no member 'strokeBorder'

There is at least 2 ways to get the result like strokeBorder gives. But they are not using strokeBorder, I want solve the issue while using strokeBorder.

0 Answers
Related