Skip to content

Instantly share code, notes, and snippets.

View igorpavlov-zz's full-sized avatar

Igor Pavlov igorpavlov-zz

  • London, UK
View GitHub Profile
// Original
Task1(param, {
config: config
})
.then(function (result) {
return Task2(result);
});
.then(Task3);
.then(function (result) {
/*! adapterjs - v0.14.0 - 2016-10-03 */
var AdapterJS = AdapterJS || {};
"undefined" != typeof exports && (module.exports = AdapterJS), AdapterJS.options = AdapterJS.options || {}, AdapterJS.VERSION = "0.14.0", AdapterJS.onwebrtcready = AdapterJS.onwebrtcready || function(isUsingPlugin) {}, AdapterJS._onwebrtcreadies = [], AdapterJS.webRTCReady = function(callback) {
if ("function" != typeof callback) throw new Error("Callback provided is not a function");
!0 === AdapterJS.onwebrtcreadyDone ? callback(null !== AdapterJS.WebRTCPlugin.plugin) : AdapterJS._onwebrtcreadies.push(callback)
}, AdapterJS.WebRTCPlugin = AdapterJS.WebRTCPlugin || {}, AdapterJS.WebRTCPlugin.pluginInfo = AdapterJS.WebRTCPlugin.pluginInfo || {
prefix: "Tem",
plugName: "TemWebRTCPlugin",
pluginId: "plugin0",
type: "application/x-temwebrtcplugin",
@igorpavlov-zz
igorpavlov-zz / gist:18af35999f8c7838cf21
Created February 22, 2015 00:24
AppRTC main JS code
var RTCPeerConnection = null;
var getUserMedia = null;
var attachMediaStream = null;
var reattachMediaStream = null;
var webrtcDetectedBrowser = null;
var webrtcDetectedVersion = null;
function trace(text) {
if (text[text.length - 1] === "\n") {
text = text.substring(0, text.length - 1);