Screenshare IOS not working as expected

Hi,

I can’t get screensharing on IOS (React-native) we are using custom frontend using lib-jitsi-meet API.

The problem is that , on ios on “screenshare” is clicked , we invoke the permission prompt via

const reactTag = findNodeHandle(this.screenCaptureView.current);
return NativeModules.ScreenCapturePickerViewManager.show(reactTag);

We then add a event listener to listen for the permission when “allowed” or “notAllowed”

const {AudioMode, IsScreenCapturedIos} = NativeModules;
 if (IsScreenCapturedIos) {
     const ScreenCaptureEmitter = new NativeEventEmitter(IsScreenCapturedIos);
    this.ScreenCaptureEmitterSubscriptionIos =
    ScreenCaptureEmitter.addListener('isScreenCaptured', data => {
           data ? this.handleStartScreenShare() : this.handlePauseScreenShare();
         });
    }

We have confirmed that on the button press , the “ios native” popup for broadcast is shown with a real device. After this action the “isScreenCaptured” event is never triggered , hence the screen is not broadcasted, we get a blackscreen.

Any help what could be wrong here ? @saghul