Imagine that your application has stored something in the
localStorage while the user has been interacting with the application. An example of this might be if you were working in a word processing application and it auto saves what you have typed to the box every so often. If your application were offline, it can still save the information.
Let's see how we would access this.
LocalStorageobject will require us to case the
WebDriverobject to it. This is similar to what we saw with
LocalStorage storageDriver = (LocalStorage) driver; storageDriver.size(); ...