Chapter 7. Choosing Intelligent Defaults
In the previous chapter, we addressed the problem of conflicts that occur when we are offline. Thanks to our offline PouchDB instance, we were able to track revisions while offline and reconcile the changes when we are back online. When multiple resolutions exist, we let the user choose which one to keep and dispose of the others. In the future, if we implemented an undo feature, we would see a linear revision history with no branches.
In this chapter, we will look at the low-hanging fruit that we've ignored up until now. Many of these things are trivial. When we load the app while offline, the Google Maps API leaves an ugly error message. When no to-do lists or to-do items exist, the screen is empty instead of providing a hint of what to do next. When the user reopens the app, they probably want to come back to whatever they were viewing last.
These are simple things and we can fix them easily. There are a few other defaults that involve...