{"id":46366,"date":"2020-02-14T10:15:37","date_gmt":"2020-02-14T18:15:37","guid":{"rendered":"http:\/\/devblogs.microsoft.com\/xamarin\/?p=46366"},"modified":"2020-02-14T10:24:16","modified_gmt":"2020-02-14T18:24:16","slug":"androidx-nuget-packages-are-stable","status":"publish","type":"post","link":"https:\/\/devblogs.microsoft.com\/xamarin\/androidx-nuget-packages-are-stable\/","title":{"rendered":"AndroidX NuGet Packages are Stable!"},"content":{"rendered":"<p>Last year, we introduced AndroidX for Xamarin. In addition to that, today we are happy to bring you stable AndroidX NuGet packages!<\/p>\n<p>Furthermore, since AndroidX is a big transition for your Android projects, we have also introduced a number of ways to migrate your Xamarin Android projects.<\/p>\n<h2>AndroidX NuGet Migration Tooling<\/h2>\n<p>There are three migration steps to be aware of regarding your application.<\/p>\n<ol>\n<li>Your application <strong>includes Android Support Library namespaces in need of migration to AndroidX namespaces<\/strong>. Use the <code>Migrate to AndroidX<\/code> IDE tooling to handle most namespace scenarios.<\/li>\n<\/ol>\n<p>First, enable the <code>AndroidX Migrator<\/code> inside <strong>Visual Studio 2019 Preview 16.5+<\/strong> via: <code>Tools &gt; Options &gt; Xamarin &gt; Android Settings<\/code>. (You can skip this step on Visual Studio for Mac 8.5+)<\/p>\n<p><center><img decoding=\"async\" class=\"aligncenter size-full wp-image-46367\" src=\"http:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2020\/02\/AndroidXMigrator.png\" alt=\"Image AndroidXMigrator AndroidX NuGet Packages\" width=\"744\" height=\"434\" srcset=\"https:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2020\/02\/AndroidXMigrator.png 744w, https:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2020\/02\/AndroidXMigrator-300x175.png 300w\" sizes=\"(max-width: 744px) 100vw, 744px\" \/><\/center><\/p>\n<p>Next, right-click your project and <span data-token-index=\"1\" data-reactroot=\"\">Migrate to AndroidX<\/span>.<\/p>\n<p><center><img decoding=\"async\" class=\"aligncenter size-full wp-image-46368\" src=\"http:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2020\/02\/MigrateToAndroidX.png\" alt=\"Image MigrateToAndroidX AndroidX NuGet Packages\" width=\"294\" height=\"530\" srcset=\"https:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2020\/02\/MigrateToAndroidX.png 294w, https:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2020\/02\/MigrateToAndroidX-166x300.png 166w\" sizes=\"(max-width: 294px) 100vw, 294px\" \/><\/center><\/p>\n<p><strong>Note:<\/strong> You will need to make some manual namespace changes for a few scenarios our tool doesn&#8217;t cover. While we will map the correct package for you, we encourage you to review the official <a href=\"https:\/\/developer.android.com\/jetpack\/androidx\/migrate\/artifact-mappings\" target=\"_blank\" rel=\"noopener noreferrer\" data-token-index=\"2\" data-reactroot=\"\">artifact mappings<\/a>. As well as the <a href=\"https:\/\/developer.android.com\/jetpack\/androidx\/migrate\/class-mappings\" target=\"_blank\" rel=\"noopener noreferrer\" data-token-index=\"4\" data-reactroot=\"\">class mappings<\/a> to help with your project migration.<\/p>\n<ol start=\"2\">\n<li>Your application <strong>includes any dependencies that have not been migrated to the AndroidX namespace<\/strong>. Use the <a href=\"https:\/\/www.nuget.org\/packages\/Xamarin.AndroidX.Migration\">Android Support Library to AndroidX Migration package<\/a>.<\/li>\n<li>Your application <strong>does not include any dependencies that require AndroidX namespace migration<\/strong>. Use the <a href=\"https:\/\/www.nuget.org\/packages?q=Tags%3A%22AndroidX%22+Authors%3A%22Microsoft%22\">AndroidX libraries available on NuGet today<\/a>.<\/li>\n<\/ol>\n<h2>How This May Affect You<\/h2>\n<p>The majority of packages you know and love have already migrated to AndroidX on Android 10 and above. Starting with <a href=\"https:\/\/docs.microsoft.com\/en-us\/xamarin\/xamarin-forms\/release-notes\/4.5\/4.5.0-pre2#androidx\">Xamarin.Forms 4.5, AndroidX will replace the Android Support Libraries.<\/a> Additionally, once this is supported in Xamarin.Forms, we will migrate <a href=\"https:\/\/github.com\/xamarin\/Essentials\/issues\/916\">Xamarin.Essentials to AndroidX<\/a>.<\/p>\n<p>As everything slowly migrates to AndroidX in favor of the Support Libraries, we will make our &#8220;out-of-box&#8221; IDE experience the default to using AndroidX and Android 10.<\/p>\n<h2>Try the AndroidX NuGet Packages Today<\/h2>\n<p>We are continuously improving this experience and want to know your thoughts! For any issues with AndroidX or Xamarin, please\u00a0<a href=\"https:\/\/docs.microsoft.com\/en-us\/visualstudio\/ide\/how-to-report-a-problem-with-visual-studio\">file an issue on Developer Community<\/a>. You may also file an issue within the <a href=\"https:\/\/github.com\/xamarin\/AndroidX\">Xamarin AndroidX GitHub repository<\/a>.<\/p>\n<p>Additionally, share any suggestions for how we can improve the AndroidX experience by <a href=\"https:\/\/docs.microsoft.com\/en-us\/visualstudio\/ide\/suggest-a-feature\">filing a suggestion on Developer Community.<\/a><\/p>\n<p>Lastly, check out our <a href=\"https:\/\/github.com\/xamarin\/XamarinAndroidXMigration\">Xamarin AndroidX Migration GitHub repository<\/a> for some tips and tricks in using the package, known issues, and limitations!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Today we are happy to bring you stable AndroidX NuGet packages. Since AndroidX is a large change for your Android projects, we\u2019ve introduced a number of ways for you to migrate your project. Learn more!<\/p>\n","protected":false},"author":551,"featured_media":46475,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[313,1,291],"tags":[6334,8036,6988],"class_list":["post-46366","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-android","category-xamarin","category-xamarin-platform","tag-androidx","tag-nuget","tag-xamarin-android"],"acf":[],"blog_post_summary":"<p>Today we are happy to bring you stable AndroidX NuGet packages. Since AndroidX is a large change for your Android projects, we\u2019ve introduced a number of ways for you to migrate your project. Learn more!<\/p>\n","_links":{"self":[{"href":"https:\/\/devblogs.microsoft.com\/xamarin\/wp-json\/wp\/v2\/posts\/46366","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/devblogs.microsoft.com\/xamarin\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/devblogs.microsoft.com\/xamarin\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/xamarin\/wp-json\/wp\/v2\/users\/551"}],"replies":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/xamarin\/wp-json\/wp\/v2\/comments?post=46366"}],"version-history":[{"count":0,"href":"https:\/\/devblogs.microsoft.com\/xamarin\/wp-json\/wp\/v2\/posts\/46366\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/xamarin\/wp-json\/wp\/v2\/media\/46475"}],"wp:attachment":[{"href":"https:\/\/devblogs.microsoft.com\/xamarin\/wp-json\/wp\/v2\/media?parent=46366"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/xamarin\/wp-json\/wp\/v2\/categories?post=46366"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/xamarin\/wp-json\/wp\/v2\/tags?post=46366"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}