What exactly is Android Jetpack?

I've seen the developer keynote of Google I/O 2018, and I've read the jetpack homepage on Android developer website, but I cannot make sense of what it actually is. To me it seems like just a new name for a bunch of APIs we already use. Is there going to be something that the IDE does for us or something that's helpful while coding? All the components in Jetpack point to their original Android documentation, and don't actually showcase any difference than before. Can someone explain in simple terms what Jetpack actually does for me as a developer, apart from clubbing documentation on a web page?


On its official site, it says:

Android Jetpack is a set of libraries, tools and architectural guidance to help make it quick and easy to build great Android apps. It provides common infrastructure code so you can focus on what makes your app unique

Technically, it is the support library, android-ktx and the Android Architecture Components re-branded as a single modular "entity".

This is why all non-Android extension libraries like support, etc. are re-packaged to androidx.**.

Quote from Alan Viverette (from Android Framework Team):

Jetpack is a larger-scoped effort to improve developer experience, but AndroidX forms the technical foundation. From a technical perspective, it's still the same libraries you'd have seen under Support Library and Architecture Components.

As best practices change, you may also see libraries in the androidx.* package that are not included in Jetpack.

See https://developer.android.com/topic/libraries/support-library/refactor for more info.


Basically it is just set of useful things combined and sorted under 4 categories

Foundation

Architecture

Behavior

UI

Some of the core things like AppCompat library, Architecture components, Fragments, Animation and transitions and many more were added now in relative categories and these 5 things were newly added.

  1. Android Ktx

    The purpose of Android KTX is to make Android development with Kotlin more concise, pleasant, and idiomatic by leveraging Kotlin language features such as extension functions/properties, lambdas, named parameters, and parameter default values

  2. Navigation

    The Navigation Architecture Component simplifies the implementation of navigation in an Android app.This is related to implementing a clear flow in your app. Here in this video you can find a very nice explanation about this topic.

  3. Paging

    The Paging Library makes it easier for you to load data gradually and gracefully within your app's RecyclerView. Here is the I/O talk from Yigit Boyar, It's very well explained by him.

  4. Slices

    Slices are UI templates that can display rich, dynamic, and interactive content from your app from within the Google Search app and later in other places like the Google Assistant. Slices can help users perform tasks faster by enabling engagement outside of the full screen app experience. You can build Slices as enhancements to App Actions. Learn more from this talk

  5. WorkManager [ I personally recommend you to check this thing out ]

    You can gracefully schedule tasks with WorkManager.The WorkManager API makes it easy to specify deferrable, asynchronous tasks and when they should run. These APIs let you create a task and hand it off to WorkManager to run immediately or at an appropriate time. This Video explains it in depth.

    I have created a playlist Here. It consists all best videos related to Jetpack, Hope this helps.


Android Jetpack is a collection of Android software components which helps us in building great Android apps.

These software components help in:

  • Following the best practices and writing the boilerplate code.
  • Making complex things very simple.

Earlier there were many challenges which are as follows:

  • Managing activity lifecycles.
  • Surviving configuration changes.
  • Preventing memory leaks.

All these major problems have been solved by the Android Jetpack's software components.

So, the solution for all the problems is Andriod Jetpack.

Another most important thing about the Jetpack is that it gets updated more frequently than the Android platform so that we always get the latest version.

Jetpack comprises the androidx.* package libraries, unbundled from the platform APIs. This means that it offers backward compatibility.

Android Jetpack Components

Android Jetpack components are a collection of libraries that are individually adoptable and built to work together while taking advantage of Kotlin language features that make us more productive.

These software components have been arranged in 4 categories which are as follows:

  • Foundation Components
  • Architecture Components
  • Behavior Components
  • UI Components

Let's see one by one.

Foundation Components

The foundation components provide the following:

  • Backward compatibility
  • Testing
  • Kotlin language support.

All the foundation components are as follows:

  • App Compat
  • Android KTX
  • Multidex
  • Test

Architecture Components

The architecture components help us in building:

  • Robust Apps
  • Testable Apps
  • Maintainable Apps

All the architecture components are as follows:

  • Data Binding
  • Lifecycles
  • LiveData
  • Navigation
  • Paging
  • Room
  • ViewModel
  • WorkManager

Behavior Components

The behavior components help in the integration with standard Android services like

  • Notifications
  • Permissions
  • Sharing
  • Assistant

All the behavior components are as follows:

  • Download Manager
  • Media & playback
  • Notifications
  • Permissions
  • Preferences
  • Sharing
  • Slices

UI Components

The UI components provide widgets and helpers to make your app not only easy, but delightful to use.

All the UI components are as follows:

  • Animation and transitions
  • Auto
  • Emoji
  • Fragment
  • Layout
  • Palette
  • TV
  • Wear

Reference article


From the blog:

Android Jetpack is the next generation of Android components, bringing together the benefits of the Support Library -- backwards compatibility and immediate updates -- to a larger set of components, making it quick and easy to build robust, high quality apps. Android Jetpack manages activities like background tasks, navigation, and lifecycle management, so you can eliminate boilerplate code and focus on what makes your app great. Android Jetpack is designed to work well with Kotlin, saving you even more code with Android KTX. The new Android Jetpack components released today include WorkManager, Paging, Navigation, and Slices.

From official doc:

Android Jetpack is a set of libraries, developer tools and architectural guidance to help make it quick and easy to build great Android apps. It provides common infrastructure code so you can focus on what makes your app unique.

enter image description here