title: How to set custom highlighted state of SwiftUI Button
body: <p>I have a Button. I want to set custom background color for highlighted state. How can I do it in SwiftUI?</p>
  
  <p><a href="https://i.stack.imgur.com/9aYkU.png" rel="noreferrer"><img src="https://i.stack.imgur.com/9aYkU.png" alt="enter image description here"></a></p>
  
  <pre><code>Button(action: signIn) {
      Text("Sign In")
  }
  .padding(.all)
  .background(Color.red)
  .cornerRadius(16)
  .foregroundColor(.white)
  .font(Font.body.bold())
  </code></pre>