setAPNSListener
Introduction
Set the specified listener for APNS on Apple iOS devices.
Set the specified listener for APNS on Apple iOS devices.
Invoke setAPNSListener() first, following by calling doBackground.
Parameter details
This API has no parameters
Returned template
void
Return value details
This function has no return value
Code example
import { TencentImSDKPlugin } from 'react-native-tim-js';
TencentImSDKPlugin.v2TIMManager.setAPNSListener();
const doBackgroundRes = await TencentImSDKPlugin.v2TIMManager
.getOfflinePushManager()
.doBackground(0);
if (doBackgroundRes.code === 0) {
}