Chapter 23

  1. Why are operations in the AsyncStorage API asynchronous?
    1. To avoid interfering with the responsiveness of the UI.
  2. Which AsyncStorage API would you use to look up several items at once?
    1. A combination of AsyncStorage.getAllKeys() and AsyncStorage.multiGet().
  3. How do you get the connectivity status of the device in a React Native application?
    1. You call NetInfo.getConnectionInfo() and read the resulting connection type.
  4. How do you respond to a change in connectivity status in a React Native application?
    1. You can listen to the connectionChange event by calling NetInfo.addEventListener('connectionChange', ...).
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.19.31.73