title: SwiftUI: Number pad layout
body: <p>I'm building a custom number pad in Swift UI. I want the buttons to be arranged in a grid that fills the screen. The only way I've found to do this for far is to use <code>GeometryReader</code> but this seems like overkill for this simple task. Is there a better way to write this?</p>
  
  <pre><code>GeometryReader { geometry in
      HStack(spacing: 0) {
          ForEach([a, b, c]) { n in
              Button(action: { self.add(n) }) { Text("\(n)") }
                  .frame(width: geometry.size.width/3)
          }
      }
  }.frame(height: 80)
  </code></pre>
  
  <p>This results in this, which is how I want it to look. Just curious if there is a good way to do this without <code>GeometryReader</code>.</p>
  
  <p><a href="https://i.stack.imgur.com/nWE4W.png" rel="noreferrer"><img src="https://i.stack.imgur.com/nWE4W.png" alt="enter image description here"></a></p>