const pc = new RTCPeerConnection();
// …
const sd = pc.currentLocalDescription;
if (sd) {
alert(`Local session: type='${sd.type}'; sdp description='${sd.sdp}'`);
} else {
alert("No local session yet.");
}RTCPeerConnection: currentLocalDescription property
Runnable notebook: every JavaScript, HTML and CSS example on this page executes in a sandboxed local frame. Nothing leaves the browser.