SwiftUI: Set a Max Width on Spacer()

Published under Mango Snippets, Oct 5, 0202

SwiftUI's Spacer() has a minLength parameter, but some times we also want a maxLength. There isn't one, but you can use .frame(maxWidth:) to achieve the same effect:

Spacer()
    .frame(maxWidth: 16)