I am trying to use this button (Start Game) to change a variable and run a function. How do I do so?
Button(action: self.addNewToDo, label: { Text("Start Game") .bold() .font(.title)
Button(action: toggleView = true, label: { Text("Start Game") .bold() .font(.title)
2.1m questions
2.1m answers
60 comments
57.0k users