Paths animation of SVG file using SVGKit

Did you ever want to create this fancy SVG file draw paths animation in iOS app? This is quite easy when you use one of the best SVG libraries for iOS.

How to do this? First of all — import SVGKit to your project. For example by using pods:

Then create UIView (let’s call it myView), position it and call code below:

Code above call animateCALayer:(CALayer *)layer duration:(CFTimeInterval)duration method which should look like this:

This code will draw on screen file from `path_to_your_svg_file` with 2 seconds duration.