Your First iOS & SwiftUI App: Polishing the App, Episode 2: More View Modifiers | raywenderlich.com

Learn about more view modifiers including padding, foregroundColor, background, and cornerRadius, and use those to style the “Hit Me” button in Bull’s Eye.


This is a companion discussion topic for the original entry at https://www.raywenderlich.com/28797859-your-first-ios-swiftui-app-polishing-the-app/lessons/2

I have made my button like below.
Button(“Hit me”) {
alertIsVisible = true
}

However, I can’t find out how to change the font inside the button.
Could you teach me the solution?

1 Like

I am having the same problem, it won’t let me put any modifiers on the text no matter where I put them (neither before the curly braces nor within them). I’ve tried turning to Google but it’s also not turning up any answers.