Member-only story

Button Styles in SwiftUI

Jay Wilson
Oct 16, 2019

This is a table explaining the different button styles in SwiftUI and which platform each Button Style is available on.

How to use

Here is sample code of how to use a Button Style in SwiftUI.

Button(action: {
print("plain")
}) {
Text("Borderless button")
}.buttonStyle(BorderlessButtonStyle())

In the GitHub repo, there is an Xcode project with each button style used.

If you enjoyed this post and want more, please consider subscribing to my Patreon and checking out my other posts!

If you don’t like having more subscriptions, consider buying me a coffee by clicking this link.

The author made this story available to Medium members only.
If you’re new to Medium, create a new account to read this story on us.

Or, continue in mobile web

Already have an account? Sign in

Jay Wilson
Jay Wilson

Written by Jay Wilson

I like to solve problems using Swift, make YouTube videos, and take photos. I also really enjoy a good cup of coffee.

No responses yet

Write a response