These are chat archives for andyet/SimpleWebRTC

26th
Jun 2016
azedine--taha
@azedine--taha
Jun 26 2016 02:57
Hello i an new in webrtc . so i want make a test for echange message peer to peer i use simplepeer.js i have error in my console Peer is not defined code
 var p = new Peer({ initiator: location.hash === '#1', trickle: false })

p.on('error', function (err) { console.log('error', err) })

p.on('signal', function (data) {
  console.log('SIGNAL', JSON.stringify(data))
  document.querySelector('#outgoing').textContent = JSON.stringify(data)
})
document.querySelector('form').addEventListener('submit', function (ev) {
  ev.preventDefault()
  p.signal(JSON.parse(document.querySelector('#incoming').value))
})

p.on('connect', function () {
  console.log('CONNECT')
  p.send('whatever' + Math.random())
})

p.on('data', function (data) {
  console.log('data: ' + data)
})'
azedine--taha
@azedine--taha
Jun 26 2016 03:02
This message was deleted
kirikou213
@kirikou213
Jun 26 2016 10:53
hi
azedine--taha
@azedine--taha
Jun 26 2016 13:14
hi