I'm learning to use this popular animation framework on Github: https://github.com/lkzhao/Hero
I built a test project, like this:
This is my ViewController
:
class ViewController: UIViewController {
@IBOutlet weak var animationObject: UIImageView!
override func viewDidLoad() {
super.viewDidLoad()
isHeroEnabled = true
animationObject.heroModifiers = [.fade, .translate(x:0, y:-250), .rotate(x:-1.6), .scale(1.5)]
}
}
When I ran the project, the view doesn't move. I have no idea how to make it work from the wiki page of Hero
, so is there somebody who can give me a hint?
Hero is the library for ViewController
transition, so you needs at least two ViewController
to see transition effect.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With