eivindml
eivindml

Reputation: 2530

Problems using iosrtc plugin in hybrid Cordova iOS app

I'm creating a native iOS app, where I'm adding in Cordova to use the CDVViewController for one controller. This works as it should. I'm then adding cordova-plugin-iosrtc to add WebRTC capabilities to that web view.

If I'm creating a complete Cordova app from scratch, I'm able to get it to work, but not while doing it as a part of the native app. Everything works, until I try to make a call, then I get this error:

ERROR: Method 'getUserMedia:' not defined in Plugin 'iosrtcPlugin'

Any ideas?

Upvotes: 3

Views: 481

Answers (1)

Alexey Tolstov
Alexey Tolstov

Reputation: 31

If your project uses swift version 4 or higher try to add attribute @objcMembers to the iosrtcPlugin, its allow to access to swift functions when its called by objc code

@objcMembers class iosrtcPlugin : CDVPlugin

Upvotes: 3

Related Questions