Offline Support

Apply what you’ve learned about a Repository pattern to build offline support in this lesson.

Usage of Blog Repository

Now that we have all the necessary pieces to implement offline support, we can finally use them in the MainActivity.

Start by creating a BlogRepository object in the onCreate method (1).

In the OnRefreshListener, we are going to call the ...