peerjs config

This commit is contained in:
Kevin Jahns
2014-08-17 01:07:40 +02:00
parent c27618bc0a
commit 8aa5dc9866
10 changed files with 17 additions and 15 deletions

View File

@@ -14,7 +14,7 @@ A working widget implementation is [IwcJson.xml](./IwcJson.xml) and the js-file
```js
function init(){
Y.createPeerJsConnector(function(Connector, user_id){
Y.createIwcConnector(function(Connector, user_id){
```

View File

@@ -14,7 +14,7 @@
A working widget implementation is [IwcJson.xml](./IwcJson.xml) and the js-file is [index.js](./index.js)
*/
function init(){
Y.createPeerJsConnector(function(Connector, user_id){
Y.createIwcConnector(function(Connector, user_id){
/**
yatta is the shared json object. If you change something on this object,
it will be instantly shared with all the other collaborators.

View File

@@ -15,7 +15,7 @@ Open [index.html](./index.html) in order to start collaboration.
var yatta;
function init(){
Y.createPeerJsConnector(function(Connector, user_id){
Y.createPeerJsConnector({key: 'h7nlefbgavh1tt9'}, function(Connector, user_id){
```

View File

@@ -15,7 +15,11 @@ Open [index.html](./index.html) in order to start collaboration.
var yatta;
function init(){
Y.createPeerJsConnector(function(Connector, user_id){
/**
First create the connector - the underlaying communication protocol.
Here, we use the PeerJs connector. Its first parameter is the API key that you need to specify (see [website](http://peerjs.com/))
*/
Y.createPeerJsConnector({key: 'h7nlefbgavh1tt9'}, function(Connector, user_id){
/**
TextYatta is a shared text object. If you change something on this object,
it will be instantaneously shared with all the other collaborators.