UNPKG

cordova-replay

Version:

Allows to use the iOS's ReplayKit framework

30 lines (28 loc) 1.08 kB
var exec = require('cordova/exec'); var Replay = { isAvailable: function (success, error) { exec(success, error, 'CordovaReplay', 'isAvailable'); }, startRecording: function (isMicrophoneEnabled, success, error) { exec(success, error, "CordovaReplay", "startRecording", [isMicrophoneEnabled]); }, stopRecording: function (success, error) { exec(success, error, "CordovaReplay", "stopRecording"); }, isRecording: function (success, error) { exec(success, error, "CordovaReplay", "isRecording"); }, startBroadcast: function (success, error) { exec(success, error, "CordovaReplay", "startBroadcast"); }, stopBroadcast: function (success, error) { exec(success, error, "CordovaReplay", "stopBroadcast"); }, isBroadcasting: function (success, error) { exec(success, error, "CordovaReplay", "isBroadcasting"); }, isBroadcastAvailable: function (success, error) { exec(success, error, "CordovaReplay", "isBroadcastAvailable"); } }; module.exports = Replay;