首页 > 解决方案 > Do I need to check the box Backwards Compatibillity (AppCompat) in Android Studio 3.2.1?

问题描述

I plan to design a new APP which minimum SDK is API 21, I hope to use latest AndroidX library.

Do I need to check the box Backwards Compatibillity (AppCompat) in Android Studio 3.2.1 ?

Image 1

enter image description here

Image 2

enter image description here

标签: androidandroid-studio

解决方案


不必要。您可以在不选中此框的情况下使用它。

向后兼容性是为了让您的应用程序在旧版本中显示相同。如果最低版本是 API 21,我仍然认为您应该使用向后兼容性,因为随着时间的推移,该版本将被弃用,然后您将不得不支持它以获得独特的外观。

从 Android 开发者页面

支持库提供标准框架 API 中不可用的其他便利类和功能,以便在更多设备上更轻松地进行开发和支持。

所以,回答你的问题:是的。因为 API 21 很快就会过时,你需要支持它们。

您还可以在官方网站上阅读更多内容:https ://developer.android.com/topic/libraries/support-library/


推荐阅读