Chapter 3
Communication
Section 3
WebRTC Applications Using PeerJS
This video explains how PeerJS is a client-side JavaScript library that provides an easy-to-use API to work with WebRTC. It only provides an API to exchange MediaStream (RTCPeerConnection) and arbitrary data between peers. It doesn't provide an API to work with MediaStream. It simplifies peer-to-peer data, audio, and video calls. To do this, we have to have the following: - WebSocket - Relationship between WebSocket and HTTP - WebSocket schemes - Interaction of WebSocket with proxy servers, load balancers, and firewalls - Same-origin policy for WebSocket