Screen Sharing on Android

I am trying to get the screen sharing to work on the Android but I am getting the error bellow. I see that the Jitsi Android App has screen sharing so there must be a path to success.

Anyone know how to implement screen sharing on Android?

Uncaught (in promise) Error: Desktop sharing is not supported!
at X._newGetDesktopMedia (lib-jitsi-meet.min.js:1)
at X. (lib-jitsi-meet.min.js:1)
at X.newObtainAudioAndVideoPermissions (lib-jitsi-meet.min.js:1)
at Function.obtainAudioAndVideoPermissions (lib-jitsi-meet.min.js:1)
at Object.createLocalTracks (lib-jitsi-meet.min.js:17)
at a.onConnectionSuccess (index.js:142)
at a.emit (lib-jitsi-meet.min.js:1)
at I.connectionHandler (lib-jitsi-meet.min.js:1)
at u._stropheConnectionCb (lib-jitsi-meet.min.js:1)
at I.Connection._changeConnectStatus (lib-jitsi-meet.min.js:1)
at I.Connection._onSessionResultIQ (lib-jitsi-meet.min.js:1)
at (lib-jitsi-meet.min.js:1)
at lib-jitsi-meet.min.js:1
at Object.forEachChild (lib-jitsi-meet.min.js:1)
at I.Connection._dataRecv (lib-jitsi-meet.min.js:1)
at D.Bosh._onRequestStateChange (lib-jitsi-meet.min.js:1)

What sdk version are you using, I upgraded the sdk version to 3.1.0 and it worked.

Do you mean the Jitsi SDK?

Yes, the Jitsi SDK.

Thanks, I am building a Hybrid app with phonegap so instead of the SDK I am using javascript. Is there an updated Javascript that I can make plugin calls with that works?

No, the iosrtc plugin does not implement getDisplayMedia.

yes it is working, but after turning on the screen sharing option back button is not working

What about for Android? There must be some way to wrap the SDK to expose the screen sharing as a plugin.

The SDK already provides screen-sharing functionality. We don’t maintain any Cordova plugin, so you’d need to ask the authors.