Created
September 23, 2022 04:16
-
-
Save scott-lydon/516edfedfbe14bd477174ede3affbee2 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@IBAction func buyTapped(_ sender: Any) { | |
coordinator?.buySubscription(payload: "payload here") | |
} | |
// ------------------------------- | |
func buySubscription(payload: String) { | |
let vc = BuyViewController.instantiate() | |
vc.payload = payload | |
vc.coordinator = self | |
navigationController.pushViewController(vc, animated: true) | |
} | |
// ------------------------------- | |
class BuyViewController: UIViewController, Storyboarded { | |
weak var coordinator: MainCoordinator? | |
var payload: String | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment