Skip to content

Instantly share code, notes, and snippets.

@mitnick78
Created December 4, 2018 13:32
Show Gist options
  • Save mitnick78/8ed8601f48f8a2039bfd4c8e8969b3cf to your computer and use it in GitHub Desktop.
Save mitnick78/8ed8601f48f8a2039bfd4c8e8969b3cf to your computer and use it in GitHub Desktop.
UIView.animate(withDuration: 0.5, animations: {
button.transform = CGAffineTransform(rotationAngle: (CGFloat(Double.pi)))
}) { (isAnimationComplete) in
// Nested Block
UIView.animate(withDuration: 0.5) {
button.transform = CGAffineTransform(rotationAngle: (CGFloat(Double.pi * 2)))
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment