There’s a new native modifier for creating inner shadows, which can even be used on strokes like this:
var body: some View {
Circle()
.stroke(.white.shadow(.inner(color: .gray, radius: 10, x: 2, y: 2)),
lineWidth: 50)
.frame(width: 300, height: 300)
}