{"id":6235,"date":"2018-05-12T19:02:10","date_gmt":"2018-05-12T19:02:10","guid":{"rendered":"http:\/\/putridparrot.com\/blog\/?p=6235"},"modified":"2018-05-12T19:02:10","modified_gmt":"2018-05-12T19:02:10","slug":"using-lottie-in-your-uwp-apps","status":"publish","type":"post","link":"https:\/\/putridparrot.com\/blog\/using-lottie-in-your-uwp-apps\/","title":{"rendered":"Using Lottie in your UWP apps."},"content":{"rendered":"<p><a href=\"https:\/\/airbnb.design\/lottie\/#get-started\" rel=\"noopener\" target=\"_blank\">Lottie<\/a> is a library for displaying <em>After Effects<\/em> animations.<\/p>\n<p>Let&#8217;s create a UWP application to try this out.<\/p>\n<ul>\n<li>Create a UWP application<\/li>\n<li>Add the LottieUWP package via NuGet<\/li>\n<\/ul>\n<p>The easiest way to get something up and running is, head over to <a href=\"https:\/\/www.lottiefiles.com\/\" rel=\"noopener\" target=\"_blank\">LottieFiles<\/a>, find an animation and download it (you&#8217;ll be downloading a JSON file).<\/p>\n<p>Place the JSON file into the Assets folder of your UWP solution and set the <em>Build Action<\/em> to <em>Content<\/em>.<\/p>\n<p>Now, in the MainPage.xaml place the following code with the <em>Grid<\/em><\/p>\n<pre class=\"brush: xml; title: ; notranslate\" title=\"\">\r\n&lt;lottieUwp:LottieAnimationView \r\n   FileName=&quot;Assets\/success_animation.json&quot; \r\n   AutoPlay=&quot;True&quot; VerticalAlignment=&quot;Center&quot; \r\n   HorizontalAlignment=&quot;Center&quot; \r\n   RepeatCount=&quot;0&quot; \r\n   Width=&quot;100&quot; Height=&quot;100&quot;\/&gt;\r\n<\/pre>\n<p>The namespace is <\/p>\n<pre class=\"brush: xml; title: ; notranslate\" title=\"\">\r\nxmlns:lottieUwp=&quot;using:LottieUWP&quot;\r\n<\/pre>\n<p>It&#8217;s as easy as that.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Lottie is a library for displaying After Effects animations. Let&#8217;s create a UWP application to try this out. Create a UWP application Add the LottieUWP package via NuGet The easiest way to get something up and running is, head over to LottieFiles, find an animation and download it (you&#8217;ll be downloading a JSON file). Place [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[215,106],"tags":[],"class_list":["post-6235","post","type-post","status-publish","format-standard","hentry","category-lottie","category-universal-app"],"jetpack_sharing_enabled":true,"jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/putridparrot.com\/blog\/wp-json\/wp\/v2\/posts\/6235","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/putridparrot.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/putridparrot.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/putridparrot.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/putridparrot.com\/blog\/wp-json\/wp\/v2\/comments?post=6235"}],"version-history":[{"count":2,"href":"https:\/\/putridparrot.com\/blog\/wp-json\/wp\/v2\/posts\/6235\/revisions"}],"predecessor-version":[{"id":6237,"href":"https:\/\/putridparrot.com\/blog\/wp-json\/wp\/v2\/posts\/6235\/revisions\/6237"}],"wp:attachment":[{"href":"https:\/\/putridparrot.com\/blog\/wp-json\/wp\/v2\/media?parent=6235"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/putridparrot.com\/blog\/wp-json\/wp\/v2\/categories?post=6235"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/putridparrot.com\/blog\/wp-json\/wp\/v2\/tags?post=6235"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}