I am working on an app which consists of an Apple Watch component. Once the iPhone app is launched, it will send information (device id, IP address, etc.) to Apple Watch via the WatchConnectivity framework and data will be stored to user defaults. The Apple Watch will use the information to send data to the server. But in some scenarios, the values from NSUserDefaults returns as "null".
For example
- When the watch is switched on and off.
- When the app is killed and not opened etc.
Please give some suggestions for storing data on Apple Watch permanently and without being dependent on iPhone every time.