The SDK supports integrations with Native platforms such as iOS and Android. This is done with the help of a Web View.
To ensure that the SDK loads up inside an Android WebView. Make sure the following permissions are present in the Manifest
The following settings on the WebView are also necessary to ensure the SDK has the necessary permissions.
The lifecycle of a WebPage in WebView is coupled to the Android app lifecycle. Therefore for proper user experience, we need to notify Haptik SDK when the app goes in background. Below is the code snippet to do so.
iOS doesn't need any extra permissions in order to operate. Just open the html file where you've configured the SDK inside the app.
Just like Android, in iOS as well the lifecycle of a WebPage is coupled to the iOS app lifecycle. We need to notify Haptik SDK when the app goes in background. To do this, please add inactive state observer in your view controller which consists the WkWebView and add the following code: