Do's and Don ' TS for Android development

Source: Internet
Author: User

Do's and Don ' TS for Android development, by Futurice developers

  1. Use Gradle and its recommended project structure
  2. Put passwords and sensitive data in gradle.properties
  3. Don ' t write your own HTTP client, use volley or OkHttp libraries
  4. Use the Jackson library to parse JSON data
  5. Avoid Guava and use only a few libraries due to the 65k method limit
  6. Use fragments to represent a UI screen
  7. Use activities just to manage fragments
  8. Layout xmls is code, organize them well
  9. Use styles to avoid duplicate attributes in Layout xmls
  10. Use multiple style files to avoid a single huge one
  11. Keep your colors.xml short and DRY, just define the palette
  12. Also Keep Dimens.xml DRY, define generic constants
  13. Do not make a deep hierarchy of viewgroups
  14. Avoid client-side processing for webviews, and beware of leaks
  15. Use Robolectric for unit tests, Robotium for Connected (UI) tests
  16. Use genymotion as your emulator
  17. Always use Proguard or Dexguard

Read more about the original: Https://github.com/benniaobuguai/android-best-practices#use-gradle-and-its-recommended-project-structure

Do's and Don ' TS for Android development

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.