FRE-600: Fix code review blockers

- Consolidated duplicate UndoManagers to single instance
- Fixed connection promise to only resolve on 'connected' status
- Fixed WebSocketProvider import (WebsocketProvider)
- Added proper doc.destroy() cleanup
- Renamed isPresenceInitialized property to avoid conflict

Co-Authored-By: Paperclip <noreply@paperclip.ing>
This commit is contained in:
2026-04-25 00:08:01 -04:00
parent 65b552bb08
commit 7c684a42cc
48450 changed files with 5679671 additions and 383 deletions

22
node_modules/peerjs/LICENSE generated vendored Normal file
View File

@@ -0,0 +1,22 @@
Copyright (c) 2015 Michelle Bu and Eric Zhang, http://peerjs.com
(The MIT License)
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

277
node_modules/peerjs/README.md generated vendored Normal file
View File

@@ -0,0 +1,277 @@
# PeerJS: Simple peer-to-peer with WebRTC
[![Backers on Open Collective](https://opencollective.com/peer/backers/badge.svg)](#backers)
[![Sponsors on Open Collective](https://opencollective.com/peer/sponsors/badge.svg)](#sponsors)
[![Discord](https://img.shields.io/discord/1016419835455996076?color=5865F2&label=Discord&logo=discord&logoColor=white)](https://discord.gg/Ud2PvAtK37)
PeerJS provides a complete, configurable, and easy-to-use peer-to-peer API built on top of WebRTC, supporting both data channels and media streams.
## Live Example
Here's an example application that uses both media and data connections: https://glitch.com/~peerjs-video. The example also uses its own [PeerServer](https://github.com/peers/peerjs-server).
---
<p align="center">
<sup>Special Announcement:</sup>
<br>
<a href="https://discord.gg/Ud2PvAtK37">
<img width="70px" src="https://assets-global.website-files.com/6257adef93867e50d84d30e2/625e5fcef7ab80b8c1fe559e_Discord-Logo-Color.png" />
</a>
<br>
<sub><b>We now have a Discord Channel</b></sub>
<br>
<sub>There we plan to discuss roadmaps, feature requests, and more<br><a href="https://discord.gg/Ud2PvAtK37">Join us today</a></sub>
</p>
---
## Setup
**Include the library**
with npm:
`npm install peerjs`
with yarn:
`yarn add peerjs`
```js
// The usage -
import { Peer } from "peerjs";
```
**Create a Peer**
```javascript
const peer = new Peer("pick-an-id");
// You can pick your own id or omit the id if you want to get a random one from the server.
```
## Data connections
**Connect**
```javascript
const conn = peer.connect("another-peers-id");
conn.on("open", () => {
conn.send("hi!");
});
```
**Receive**
```javascript
peer.on("connection", (conn) => {
conn.on("data", (data) => {
// Will print 'hi!'
console.log(data);
});
conn.on("open", () => {
conn.send("hello!");
});
});
```
## Media calls
**Call**
```javascript
navigator.mediaDevices.getUserMedia(
{ video: true, audio: true },
(stream) => {
const call = peer.call("another-peers-id", stream);
call.on("stream", (remoteStream) => {
// Show stream in some <video> element.
});
},
(err) => {
console.error("Failed to get local stream", err);
},
);
```
**Answer**
```javascript
peer.on("call", (call) => {
navigator.mediaDevices.getUserMedia(
{ video: true, audio: true },
(stream) => {
call.answer(stream); // Answer the call with an A/V stream.
call.on("stream", (remoteStream) => {
// Show stream in some <video> element.
});
},
(err) => {
console.error("Failed to get local stream", err);
},
);
});
```
## Running tests
```bash
npm test
```
## Browser support
| [<img src="https://raw.githubusercontent.com/alrra/browser-logos/master/src/firefox/firefox_48x48.png" alt="Firefox" width="24px" height="24px" />](http://godban.github.io/browsers-support-badges/)<br/>Firefox | [<img src="https://raw.githubusercontent.com/alrra/browser-logos/master/src/chrome/chrome_48x48.png" alt="Chrome" width="24px" height="24px" />](http://godban.github.io/browsers-support-badges/)<br/>Chrome | [<img src="https://raw.githubusercontent.com/alrra/browser-logos/master/src/edge/edge_48x48.png" alt="Safari" width="24px" height="24px" />](http://godban.github.io/browsers-support-badges/)<br/>Edge | [<img src="https://raw.githubusercontent.com/alrra/browser-logos/master/src/safari/safari_48x48.png" alt="Safari" width="24px" height="24px" />](http://godban.github.io/browsers-support-badges/)<br/>Safari |
| ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| 80+ | 83+ | 83+ | 15+ |
We test PeerJS against these versions of Chrome, Edge, Firefox, and Safari with [BrowserStack](https://www.browserstack.com) to ensure compatibility.
It may work in other and older browsers, but we don't officially support them.
Changes to browser support will be a breaking change going forward.
> [!NOTE]
> Firefox 102+ is required for CBOR / MessagePack support.
## FAQ
Q. I have a message `Critical dependency: the request of a dependency is an expression` in browser's console
A. The message occurs when you use PeerJS with Webpack. It is not critical! It relates to Parcel https://github.com/parcel-bundler/parcel/issues/2883 We'll resolve it when updated to Parcel V2.
## Links
### [Documentation / API Reference](https://peerjs.com/docs/)
### [PeerServer](https://github.com/peers/peerjs-server)
### [Discuss PeerJS on our Telegram Channel](https://t.me/joinchat/ENhPuhTvhm8WlIxTjQf7Og)
### [Changelog](https://github.com/peers/peerjs/blob/master/CHANGELOG.md)
## Contributors
This project exists thanks to all the people who contribute.
<a href="https://github.com/peers/peerjs/graphs/contributors"><img src="https://opencollective.com/peer/contributors.svg?width=890&button=false" /></a>
## Backers
Thank you to all our backers! [[Become a backer](https://opencollective.com/peer#backer)]
<a href="https://opencollective.com/peer/backer/0/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/0/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/1/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/1/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/2/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/2/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/3/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/3/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/4/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/4/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/5/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/5/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/6/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/6/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/7/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/7/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/8/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/8/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/9/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/9/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/10/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/10/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/11/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/11/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/12/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/12/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/13/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/13/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/14/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/14/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/15/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/15/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/16/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/16/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/17/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/17/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/18/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/18/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/19/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/19/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/20/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/20/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/21/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/21/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/22/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/22/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/23/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/23/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/24/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/24/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/25/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/25/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/26/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/26/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/27/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/27/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/28/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/28/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/29/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/29/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/30/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/30/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/31/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/31/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/32/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/32/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/33/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/33/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/34/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/34/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/35/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/35/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/36/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/36/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/37/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/37/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/38/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/38/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/39/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/39/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/40/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/40/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/41/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/41/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/42/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/42/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/43/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/43/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/44/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/44/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/45/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/45/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/46/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/46/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/47/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/47/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/48/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/48/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/49/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/49/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/50/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/50/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/51/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/51/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/52/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/52/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/53/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/53/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/54/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/54/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/55/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/55/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/56/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/56/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/57/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/57/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/58/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/58/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/59/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/59/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/60/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/60/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/61/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/61/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/62/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/62/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/63/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/63/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/64/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/64/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/65/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/65/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/66/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/66/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/67/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/67/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/68/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/68/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/69/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/69/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/70/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/70/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/71/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/71/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/72/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/72/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/73/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/73/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/74/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/74/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/75/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/75/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/76/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/76/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/77/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/77/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/78/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/78/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/79/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/79/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/80/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/80/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/81/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/81/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/82/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/82/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/83/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/83/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/84/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/84/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/85/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/85/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/86/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/86/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/87/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/87/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/88/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/88/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/89/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/89/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/90/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/90/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/91/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/91/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/92/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/92/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/93/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/93/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/94/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/94/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/95/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/95/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/96/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/96/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/97/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/97/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/98/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/98/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/99/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/99/avatar.svg?requireActive=false"/></a>
<a href="https://opencollective.com/peer/backer/100/website?requireActive=false" target="_blank"><img src="https://opencollective.com/peer/backer/100/avatar.svg?requireActive=false"/></a>
## Sponsors
Support this project by becoming a sponsor. Your logo will show up here with a link to your website. [[Become a sponsor](https://opencollective.com/peer#sponsor)]
<a href="https://opencollective.com/peer/sponsor/1/website" target="_blank"><img src="https://opencollective.com/peer/sponsor/1/avatar.svg"/></a>
<a href="https://opencollective.com/peer/sponsor/2/website" target="_blank"><img src="https://opencollective.com/peer/sponsor/2/avatar.svg"/></a>
<a href="https://opencollective.com/peer/sponsor/0/website" target="_blank"><img src="https://opencollective.com/peer/sponsor/0/avatar.svg"/></a>
<a href="https://opencollective.com/peer/sponsor/3/website" target="_blank"><img src="https://opencollective.com/peer/sponsor/3/avatar.svg"/></a>
<a href="https://opencollective.com/peer/sponsor/4/website" target="_blank"><img src="https://opencollective.com/peer/sponsor/4/avatar.svg"/></a>
<a href="https://opencollective.com/peer/sponsor/5/website" target="_blank"><img src="https://opencollective.com/peer/sponsor/5/avatar.svg"/></a>
<a href="https://opencollective.com/peer/sponsor/6/website" target="_blank"><img src="https://opencollective.com/peer/sponsor/6/avatar.svg"/></a>
<a href="https://opencollective.com/peer/sponsor/7/website" target="_blank"><img src="https://opencollective.com/peer/sponsor/7/avatar.svg"/></a>
<a href="https://opencollective.com/peer/sponsor/8/website" target="_blank"><img src="https://opencollective.com/peer/sponsor/8/avatar.svg"/></a>
<a href="https://opencollective.com/peer/sponsor/9/website" target="_blank"><img src="https://opencollective.com/peer/sponsor/9/avatar.svg"/></a>
## License
PeerJS is licensed under the [MIT License](https://tldrlegal.com/l/mit).

1670
node_modules/peerjs/dist/bundler.cjs generated vendored Normal file

File diff suppressed because it is too large Load Diff

1
node_modules/peerjs/dist/bundler.cjs.map generated vendored Normal file

File diff suppressed because one or more lines are too long

1888
node_modules/peerjs/dist/bundler.mjs generated vendored Normal file

File diff suppressed because it is too large Load Diff

1
node_modules/peerjs/dist/bundler.mjs.map generated vendored Normal file

File diff suppressed because one or more lines are too long

4715
node_modules/peerjs/dist/peerjs.js generated vendored Normal file

File diff suppressed because it is too large Load Diff

1
node_modules/peerjs/dist/peerjs.js.map generated vendored Normal file

File diff suppressed because one or more lines are too long

8
node_modules/peerjs/dist/peerjs.min.js generated vendored Normal file

File diff suppressed because one or more lines are too long

1
node_modules/peerjs/dist/peerjs.min.js.map generated vendored Normal file

File diff suppressed because one or more lines are too long

2
node_modules/peerjs/dist/serializer.msgpack.mjs generated vendored Normal file

File diff suppressed because one or more lines are too long

1
node_modules/peerjs/dist/serializer.msgpack.mjs.map generated vendored Normal file

File diff suppressed because one or more lines are too long

643
node_modules/peerjs/dist/types.d.ts generated vendored Normal file
View File

@@ -0,0 +1,643 @@
import * as BinaryPack from "peerjs-js-binarypack";
import { EventEmitter, ValidEventTypes } from "eventemitter3";
declare class BinaryPackChunker {
readonly chunkedMTU = 16300;
chunk: (blob: ArrayBuffer) => {
__peerData: number;
n: number;
total: number;
data: Uint8Array;
}[];
}
export interface UtilSupportsObj {
/**
* The current browser.
* This property can be useful in determining whether two peers can connect.
*
* ```ts
* if (util.browser === 'firefox') {
* // OK to peer with Firefox peers.
* }
* ```
*
* `util.browser` can currently have the values
* `'firefox', 'chrome', 'safari', 'edge', 'Not a supported browser.', 'Not a browser.' (unknown WebRTC-compatible agent).
*/
browser: boolean;
webRTC: boolean;
/**
* True if the current browser supports media streams and PeerConnection.
*/
audioVideo: boolean;
/**
* True if the current browser supports DataChannel and PeerConnection.
*/
data: boolean;
binaryBlob: boolean;
/**
* True if the current browser supports reliable DataChannels.
*/
reliable: boolean;
}
export class Util extends BinaryPackChunker {
noop(): void;
readonly CLOUD_HOST = "0.peerjs.com";
readonly CLOUD_PORT = 443;
readonly chunkedBrowsers: {
Chrome: number;
chrome: number;
};
readonly defaultConfig: {
iceServers: ({
urls: string;
username?: undefined;
credential?: undefined;
} | {
urls: string[];
username: string;
credential: string;
})[];
sdpSemantics: string;
};
readonly browser: string;
readonly browserVersion: number;
pack: typeof BinaryPack.pack;
unpack: typeof BinaryPack.unpack;
/**
* A hash of WebRTC features mapped to booleans that correspond to whether the feature is supported by the current browser.
*
* :::caution
* Only the properties documented here are guaranteed to be present on `util.supports`
* :::
*/
readonly supports: UtilSupportsObj;
validateId: (id: string) => boolean;
randomToken: () => string;
blobToArrayBuffer(blob: Blob, cb: (arg: ArrayBuffer | null) => void): FileReader;
binaryStringToArrayBuffer(binary: string): ArrayBuffer | SharedArrayBuffer;
isSecure(): boolean;
}
/**
* Provides a variety of helpful utilities.
*
* :::caution
* Only the utilities documented here are guaranteed to be present on `util`.
* Undocumented utilities can be removed without warning.
* We don't consider these to be breaking changes.
* :::
*/
export const util: Util;
export enum LogLevel {
/**
* Prints no logs.
*/
Disabled = 0,
/**
* Prints only errors.
*/
Errors = 1,
/**
* Prints errors and warnings.
*/
Warnings = 2,
/**
* Prints all logs.
*/
All = 3
}
export enum ConnectionType {
Data = "data",
Media = "media"
}
export enum PeerErrorType {
/**
* The client's browser does not support some or all WebRTC features that you are trying to use.
*/
BrowserIncompatible = "browser-incompatible",
/**
* You've already disconnected this peer from the server and can no longer make any new connections on it.
*/
Disconnected = "disconnected",
/**
* The ID passed into the Peer constructor contains illegal characters.
*/
InvalidID = "invalid-id",
/**
* The API key passed into the Peer constructor contains illegal characters or is not in the system (cloud server only).
*/
InvalidKey = "invalid-key",
/**
* Lost or cannot establish a connection to the signalling server.
*/
Network = "network",
/**
* The peer you're trying to connect to does not exist.
*/
PeerUnavailable = "peer-unavailable",
/**
* PeerJS is being used securely, but the cloud server does not support SSL. Use a custom PeerServer.
*/
SslUnavailable = "ssl-unavailable",
/**
* Unable to reach the server.
*/
ServerError = "server-error",
/**
* An error from the underlying socket.
*/
SocketError = "socket-error",
/**
* The underlying socket closed unexpectedly.
*/
SocketClosed = "socket-closed",
/**
* The ID passed into the Peer constructor is already taken.
*
* :::caution
* This error is not fatal if your peer has open peer-to-peer connections.
* This can happen if you attempt to {@apilink Peer.reconnect} a peer that has been disconnected from the server,
* but its old ID has now been taken.
* :::
*/
UnavailableID = "unavailable-id",
/**
* Native WebRTC errors.
*/
WebRTC = "webrtc"
}
export enum BaseConnectionErrorType {
NegotiationFailed = "negotiation-failed",
ConnectionClosed = "connection-closed"
}
export enum DataConnectionErrorType {
NotOpenYet = "not-open-yet",
MessageToBig = "message-too-big"
}
export enum SerializationType {
Binary = "binary",
BinaryUTF8 = "binary-utf8",
JSON = "json",
None = "raw"
}
export enum SocketEventType {
Message = "message",
Disconnected = "disconnected",
Error = "error",
Close = "close"
}
export enum ServerMessageType {
Heartbeat = "HEARTBEAT",
Candidate = "CANDIDATE",
Offer = "OFFER",
Answer = "ANSWER",
Open = "OPEN",// The connection to the server is open.
Error = "ERROR",// Server error.
IdTaken = "ID-TAKEN",// The selected ID is taken.
InvalidKey = "INVALID-KEY",// The given API key cannot be found.
Leave = "LEAVE",// Another peer has closed its connection to this peer.
Expire = "EXPIRE"
}
/**
* An abstraction on top of WebSockets to provide fastest
* possible connection for peers.
*/
declare class Socket extends EventEmitter {
constructor(secure: any, host: string, port: number, path: string, key: string, pingInterval?: number);
start(id: string, token: string): void;
/** Exposed send for DC & Peer. */
send(data: any): void;
close(): void;
}
declare class ServerMessage {
type: ServerMessageType;
payload: any;
src: string;
}
interface EventsWithError<ErrorType extends string> {
error: (error: PeerError<`${ErrorType}`>) => void;
}
declare class EventEmitterWithError<ErrorType extends string, Events extends EventsWithError<ErrorType>> extends EventEmitter<Events, never> {
/**
* Emits a typed error message.
*
* @internal
*/
emitError(type: ErrorType, err: string | Error): void;
}
/**
* A PeerError is emitted whenever an error occurs.
* It always has a `.type`, which can be used to identify the error.
*/
export class PeerError<T extends string> extends Error {
/**
* @internal
*/
constructor(type: T, err: Error | string);
type: T;
}
interface BaseConnectionEvents<ErrorType extends string = BaseConnectionErrorType> extends EventsWithError<ErrorType> {
/**
* Emitted when either you or the remote peer closes the connection.
*
* ```ts
* connection.on('close', () => { ... });
* ```
*/
close: () => void;
/**
* ```ts
* connection.on('error', (error) => { ... });
* ```
*/
error: (error: PeerError<`${ErrorType}`>) => void;
iceStateChanged: (state: RTCIceConnectionState) => void;
}
declare abstract class BaseConnection<SubClassEvents extends ValidEventTypes, ErrorType extends string = never> extends EventEmitterWithError<ErrorType | BaseConnectionErrorType, SubClassEvents & BaseConnectionEvents<BaseConnectionErrorType | ErrorType>> {
/**
* The ID of the peer on the other end of this connection.
*/
readonly peer: string;
provider: Peer;
readonly options: any;
protected _open: boolean;
/**
* Any type of metadata associated with the connection,
* passed in by whoever initiated the connection.
*/
readonly metadata: any;
connectionId: string;
peerConnection: RTCPeerConnection;
dataChannel: RTCDataChannel;
abstract get type(): ConnectionType;
/**
* The optional label passed in or assigned by PeerJS when the connection was initiated.
*/
label: string;
/**
* Whether the media connection is active (e.g. your call has been answered).
* You can check this if you want to set a maximum wait time for a one-sided call.
*/
get open(): boolean;
protected constructor(
/**
* The ID of the peer on the other end of this connection.
*/
peer: string, provider: Peer, options: any);
abstract close(): void;
/**
* @internal
*/
abstract handleMessage(message: ServerMessage): void;
/**
* Called by the Negotiator when the DataChannel is ready.
* @internal
* */
abstract _initializeDataChannel(dc: RTCDataChannel): void;
}
interface DataConnectionEvents extends EventsWithError<DataConnectionErrorType | BaseConnectionErrorType>, BaseConnectionEvents<DataConnectionErrorType | BaseConnectionErrorType> {
/**
* Emitted when data is received from the remote peer.
*/
data: (data: unknown) => void;
/**
* Emitted when the connection is established and ready-to-use.
*/
open: () => void;
}
/**
* Wraps a DataChannel between two Peers.
*/
export abstract class DataConnection extends BaseConnection<DataConnectionEvents, DataConnectionErrorType> {
protected static readonly ID_PREFIX = "dc_";
protected static readonly MAX_BUFFERED_AMOUNT: number;
abstract readonly serialization: string;
readonly reliable: boolean;
get type(): ConnectionType;
constructor(peerId: string, provider: Peer, options: any);
/** Called by the Negotiator when the DataChannel is ready. */
_initializeDataChannel(dc: RTCDataChannel): void;
/**
* Exposed functionality for users.
*/
/** Allows user to close connection. */
close(options?: {
flush?: boolean;
}): void;
protected abstract _send(data: any, chunked: boolean): void | Promise<void>;
/** Allows user to send data. */
send(data: any, chunked?: boolean): void | Promise<void>;
handleMessage(message: ServerMessage): Promise<void>;
}
export interface AnswerOption {
/**
* Function which runs before create answer to modify sdp answer message.
*/
sdpTransform?: Function;
}
export interface PeerJSOption {
key?: string;
host?: string;
port?: number;
path?: string;
secure?: boolean;
token?: string;
config?: RTCConfiguration;
debug?: number;
referrerPolicy?: ReferrerPolicy;
}
export interface PeerConnectOption {
/**
* A unique label by which you want to identify this data connection.
* If left unspecified, a label will be generated at random.
*
* Can be accessed with {@apilink DataConnection.label}
*/
label?: string;
/**
* Metadata associated with the connection, passed in by whoever initiated the connection.
*
* Can be accessed with {@apilink DataConnection.metadata}.
* Can be any serializable type.
*/
metadata?: any;
serialization?: string;
reliable?: boolean;
}
export interface CallOption {
/**
* Metadata associated with the connection, passed in by whoever initiated the connection.
*
* Can be accessed with {@apilink MediaConnection.metadata}.
* Can be any serializable type.
*/
metadata?: any;
/**
* Function which runs before create offer to modify sdp offer message.
*/
sdpTransform?: Function;
}
interface MediaConnectionEvents extends BaseConnectionEvents<never> {
/**
* Emitted when a connection to the PeerServer is established.
*
* ```ts
* mediaConnection.on('stream', (stream) => { ... });
* ```
*/
stream: (stream: MediaStream) => void;
/**
* Emitted when the auxiliary data channel is established.
* After this event, hanging up will close the connection cleanly on the remote peer.
* @beta
*/
willCloseOnRemote: () => void;
}
/**
* Wraps WebRTC's media streams.
* To get one, use {@apilink Peer.call} or listen for the {@apilink PeerEvents | `call`} event.
*/
export class MediaConnection extends BaseConnection<MediaConnectionEvents> {
readonly label: string;
/**
* For media connections, this is always 'media'.
*/
get type(): ConnectionType;
get localStream(): MediaStream;
get remoteStream(): MediaStream;
constructor(peerId: string, provider: Peer, options: any);
/** Called by the Negotiator when the DataChannel is ready. */
_initializeDataChannel(dc: RTCDataChannel): void;
addStream(remoteStream: any): void;
/**
* @internal
*/
handleMessage(message: ServerMessage): void;
/**
* When receiving a {@apilink PeerEvents | `call`} event on a peer, you can call
* `answer` on the media connection provided by the callback to accept the call
* and optionally send your own media stream.
*
* @param stream A WebRTC media stream.
* @param options
* @returns
*/
answer(stream?: MediaStream, options?: AnswerOption): void;
/**
* Exposed functionality for users.
*/
/**
* Closes the media connection.
*/
close(): void;
}
export abstract class BufferedConnection extends DataConnection {
get bufferSize(): number;
_initializeDataChannel(dc: RTCDataChannel): void;
protected abstract _handleDataMessage(e: MessageEvent): void;
protected _bufferedSend(msg: ArrayBuffer): void;
close(options?: {
flush?: boolean;
}): void;
}
export class PeerOptions implements PeerJSOption {
/**
* Prints log messages depending on the debug level passed in.
*/
debug?: LogLevel;
/**
* Server host. Defaults to `0.peerjs.com`.
* Also accepts `'/'` to signify relative hostname.
*/
host?: string;
/**
* Server port. Defaults to `443`.
*/
port?: number;
/**
* The path where your self-hosted PeerServer is running. Defaults to `'/'`
*/
path?: string;
/**
* API key for the PeerServer.
* This is not used anymore.
* @deprecated
*/
key?: string;
token?: string;
/**
* Configuration hash passed to RTCPeerConnection.
* This hash contains any custom ICE/TURN server configuration.
*
* Defaults to {@apilink util.defaultConfig}
*/
config?: any;
/**
* Set to true `true` if you're using TLS.
* :::danger
* If possible *always use TLS*
* :::
*/
secure?: boolean;
pingInterval?: number;
referrerPolicy?: ReferrerPolicy;
logFunction?: (logLevel: LogLevel, ...rest: any[]) => void;
serializers?: SerializerMapping;
}
export interface SerializerMapping {
[key: string]: new (peerId: string, provider: Peer, options: any) => DataConnection;
}
export interface PeerEvents {
/**
* Emitted when a connection to the PeerServer is established.
*
* You may use the peer before this is emitted, but messages to the server will be queued. <code>id</code> is the brokering ID of the peer (which was either provided in the constructor or assigned by the server).<span class='tip'>You should not wait for this event before connecting to other peers if connection speed is important.</span>
*/
open: (id: string) => void;
/**
* Emitted when a new data connection is established from a remote peer.
*/
connection: (dataConnection: DataConnection) => void;
/**
* Emitted when a remote peer attempts to call you.
*/
call: (mediaConnection: MediaConnection) => void;
/**
* Emitted when the peer is destroyed and can no longer accept or create any new connections.
*/
close: () => void;
/**
* Emitted when the peer is disconnected from the signalling server
*/
disconnected: (currentId: string) => void;
/**
* Errors on the peer are almost always fatal and will destroy the peer.
*
* Errors from the underlying socket and PeerConnections are forwarded here.
*/
error: (error: PeerError<`${PeerErrorType}`>) => void;
}
/**
* A peer who can initiate connections with other peers.
*/
export class Peer extends EventEmitterWithError<PeerErrorType, PeerEvents> {
protected readonly _serializers: SerializerMapping;
/**
* The brokering ID of this peer
*
* If no ID was specified in {@apilink Peer | the constructor},
* this will be `undefined` until the {@apilink PeerEvents | `open`} event is emitted.
*/
get id(): string;
get options(): PeerOptions;
get open(): boolean;
/**
* @internal
*/
get socket(): Socket;
/**
* A hash of all connections associated with this peer, keyed by the remote peer's ID.
* @deprecated
* Return type will change from Object to Map<string,[]>
*/
get connections(): Object;
/**
* true if this peer and all of its connections can no longer be used.
*/
get destroyed(): boolean;
/**
* false if there is an active connection to the PeerServer.
*/
get disconnected(): boolean;
/**
* A peer can connect to other peers and listen for connections.
*/
constructor();
/**
* A peer can connect to other peers and listen for connections.
* @param options for specifying details about PeerServer
*/
constructor(options: PeerOptions);
/**
* A peer can connect to other peers and listen for connections.
* @param id Other peers can connect to this peer using the provided ID.
* If no ID is given, one will be generated by the brokering server.
* The ID must start and end with an alphanumeric character (lower or upper case character or a digit). In the middle of the ID spaces, dashes (-) and underscores (_) are allowed. Use {@apilink PeerOptions.metadata } to send identifying information.
* @param options for specifying details about PeerServer
*/
constructor(id: string, options?: PeerOptions);
/**
* Retrieve messages from lost message store
* @internal
*/
_getMessages(connectionId: string): ServerMessage[];
/**
* Connects to the remote peer specified by id and returns a data connection.
* @param peer The brokering ID of the remote peer (their {@apilink Peer.id}).
* @param options for specifying details about Peer Connection
*/
connect(peer: string, options?: PeerConnectOption): DataConnection;
/**
* Calls the remote peer specified by id and returns a media connection.
* @param peer The brokering ID of the remote peer (their peer.id).
* @param stream The caller's media stream
* @param options Metadata associated with the connection, passed in by whoever initiated the connection.
*/
call(peer: string, stream: MediaStream, options?: CallOption): MediaConnection;
_removeConnection(connection: DataConnection | MediaConnection): void;
/** Retrieve a data/media connection for this peer. */
getConnection(peerId: string, connectionId: string): null | DataConnection | MediaConnection;
/**
* Destroys the Peer: closes all active connections as well as the connection
* to the server.
*
* :::caution
* This cannot be undone; the respective peer object will no longer be able
* to create or receive any connections, its ID will be forfeited on the server,
* and all of its data and media connections will be closed.
* :::
*/
destroy(): void;
/**
* Disconnects the Peer's connection to the PeerServer. Does not close any
* active connections.
* Warning: The peer can no longer create or accept connections after being
* disconnected. It also cannot reconnect to the server.
*/
disconnect(): void;
/** Attempts to reconnect with the same ID.
*
* Only {@apilink Peer.disconnect | disconnected peers} can be reconnected.
* Destroyed peers cannot be reconnected.
* If the connection fails (as an example, if the peer's old ID is now taken),
* the peer's existing connections will not close, but any associated errors events will fire.
*/
reconnect(): void;
/**
* Get a list of available peer IDs. If you're running your own server, you'll
* want to set allow_discovery: true in the PeerServer options. If you're using
* the cloud server, email team@peerjs.com to get the functionality enabled for
* your key.
*/
listAllPeers(cb?: (_: any[]) => void): void;
}
/**
* @experimental
*/
export class MsgPackPeer extends Peer {
_serializers: SerializerMapping;
}
export abstract class StreamConnection extends DataConnection {
protected writer: WritableStreamDefaultWriter<Uint8Array<ArrayBufferLike>>;
protected _rawReadStream: ReadableStream<ArrayBuffer>;
protected constructor(peerId: string, provider: Peer, options: any);
_initializeDataChannel(dc: any): void;
}
export class MsgPack extends StreamConnection {
readonly serialization = "MsgPack";
constructor(peerId: string, provider: Peer, options: any);
protected _send(data: any): Promise<void>;
}
export default Peer;
//# sourceMappingURL=types.d.ts.map

1
node_modules/peerjs/dist/types.d.ts.map generated vendored Normal file

File diff suppressed because one or more lines are too long

217
node_modules/peerjs/package.json generated vendored Normal file
View File

@@ -0,0 +1,217 @@
{
"name": "peerjs",
"version": "1.5.5",
"keywords": [
"peerjs",
"webrtc",
"p2p",
"rtc"
],
"description": "PeerJS client",
"homepage": "https://peerjs.com",
"bugs": {
"url": "https://github.com/peers/peerjs/issues"
},
"repository": {
"type": "git",
"url": "https://github.com/peers/peerjs"
},
"license": "MIT",
"contributors": [
"Michelle Bu <michelle@michellebu.com>",
"afrokick <devbyru@gmail.com>",
"ericz <really.ez@gmail.com>",
"Jairo <kidandcat@gmail.com>",
"Jonas Gloning <34194370+jonasgloning@users.noreply.github.com>",
"Jairo Caro-Accino Viciana <jairo@galax.be>",
"Carlos Caballero <carlos.caballero.gonzalez@gmail.com>",
"hc <hheennrryy@gmail.com>",
"Muhammad Asif <capripio@gmail.com>",
"PrashoonB <prashoonbhattacharjee@gmail.com>",
"Harsh Bardhan Mishra <47351025+HarshCasper@users.noreply.github.com>",
"akotynski <aleksanderkotbury@gmail.com>",
"lmb <i@lmb.io>",
"Jairooo <jairocaro@msn.com>",
"Moritz Stückler <moritz.stueckler@gmail.com>",
"Simon <crydotsnakegithub@gmail.com>",
"Denis Lukov <denismassters@gmail.com>",
"Philipp Hancke <fippo@andyet.net>",
"Hans Oksendahl <hansoksendahl@gmail.com>",
"Jess <jessachandler@gmail.com>",
"khankuan <khankuan@gmail.com>",
"DUODVK <kurmanov.work@gmail.com>",
"XiZhao <kwang1imsa@gmail.com>",
"Matthias Lohr <matthias@lohr.me>",
"=frank tree <=frnktrb@googlemail.com>",
"Andre Eckardt <aeckardt@outlook.com>",
"Chris Cowan <agentme49@gmail.com>",
"Alex Chuev <alex@chuev.com>",
"alxnull <alxnull@e.mail.de>",
"Yemel Jardi <angel.jardi@gmail.com>",
"Ben Parnell <benjaminparnell.94@gmail.com>",
"Benny Lichtner <bennlich@gmail.com>",
"fresheneesz <bitetrudpublic@gmail.com>",
"bob.barstead@exaptive.com <bob.barstead@exaptive.com>",
"chandika <chandika@gmail.com>",
"emersion <contact@emersion.fr>",
"Christopher Van <cvan@users.noreply.github.com>",
"eddieherm <edhermoso@gmail.com>",
"Eduardo Pinho <enet4mikeenet@gmail.com>",
"Evandro Zanatta <ezanatta@tray.net.br>",
"Gardner Bickford <gardner@users.noreply.github.com>",
"Gian Luca <gianluca.cecchi@cynny.com>",
"PatrickJS <github@gdi2290.com>",
"jonnyf <github@jonathanfoss.co.uk>",
"Hizkia Felix <hizkifw@gmail.com>",
"Hristo Oskov <hristo.oskov@gmail.com>",
"Isaac Madwed <i.madwed@gmail.com>",
"Ilya Konanykhin <ilya.konanykhin@gmail.com>",
"jasonbarry <jasbarry@me.com>",
"Jonathan Burke <jonathan.burke.1311@googlemail.com>",
"Josh Hamit <josh.hamit@gmail.com>",
"Jordan Austin <jrax86@gmail.com>",
"Joel Wetzell <jwetzell@yahoo.com>",
"xizhao <kevin.wang@cloudera.com>",
"Alberto Torres <kungfoobar@gmail.com>",
"Jonathan Mayol <mayoljonathan@gmail.com>",
"Jefferson Felix <me@jsfelix.dev>",
"Rolf Erik Lekang <me@rolflekang.com>",
"Kevin Mai-Husan Chia <mhchia@users.noreply.github.com>",
"Pepijn de Vos <pepijndevos@gmail.com>",
"JooYoung <qkdlql@naver.com>",
"Tobias Speicher <rootcommander@gmail.com>",
"Steve Blaurock <sblaurock@gmail.com>",
"Kyrylo Shegeda <shegeda@ualberta.ca>",
"Diwank Singh Tomer <singh@diwank.name>",
"Sören Balko <Soeren.Balko@gmail.com>",
"Arpit Solanki <solankiarpit1997@gmail.com>",
"Yuki Ito <yuki@gnnk.net>",
"Artur Zayats <zag2art@gmail.com>"
],
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/peer"
},
"collective": {
"type": "opencollective",
"url": "https://opencollective.com/peer"
},
"files": [
"dist/*"
],
"sideEffects": [
"lib/global.ts",
"lib/supports.ts"
],
"main": "dist/bundler.cjs",
"module": "dist/bundler.mjs",
"browser-minified": "dist/peerjs.min.js",
"browser-unminified": "dist/peerjs.js",
"browser-minified-msgpack": "dist/serializer.msgpack.mjs",
"types": "dist/types.d.ts",
"engines": {
"node": ">= 14"
},
"targets": {
"types": {
"source": "lib/exports.ts"
},
"main": {
"source": "lib/exports.ts",
"sourceMap": {
"inlineSources": true
}
},
"module": {
"source": "lib/exports.ts",
"includeNodeModules": [
"eventemitter3"
],
"sourceMap": {
"inlineSources": true
}
},
"browser-minified": {
"context": "browser",
"outputFormat": "global",
"optimize": true,
"engines": {
"browsers": "chrome >= 83, edge >= 83, firefox >= 80, safari >= 15"
},
"source": "lib/global.ts"
},
"browser-unminified": {
"context": "browser",
"outputFormat": "global",
"optimize": false,
"engines": {
"browsers": "chrome >= 83, edge >= 83, firefox >= 80, safari >= 15"
},
"source": "lib/global.ts"
},
"browser-minified-msgpack": {
"context": "browser",
"outputFormat": "esmodule",
"isLibrary": true,
"optimize": true,
"engines": {
"browsers": "chrome >= 83, edge >= 83, firefox >= 102, safari >= 15"
},
"source": "lib/dataconnection/StreamConnection/MsgPack.ts"
}
},
"scripts": {
"contributors": "git-authors-cli --print=false && prettier --write package.json && git add package.json package-lock.json && git commit -m \"chore(contributors): update and sort contributors list\"",
"check": "tsc --noEmit && tsc -p e2e/tsconfig.json --noEmit",
"watch": "parcel watch",
"build": "npm run build:version && rm -rf dist && parcel build",
"build:version": "echo \"export const version = \\\"$(node -p \"require('./package.json').version\")\\\";\" > lib/version.ts",
"prepublishOnly": "npm run build",
"test": "jest",
"test:watch": "jest --watch",
"coverage": "jest --coverage --collectCoverageFrom=\"./lib/**\"",
"format": "prettier --write .",
"format:check": "prettier --check .",
"semantic-release": "semantic-release",
"e2e": "wdio run e2e/wdio.local.conf.ts",
"e2e:bstack": "wdio run e2e/wdio.bstack.conf.ts"
},
"devDependencies": {
"@parcel/config-default": "^2.9.3",
"@parcel/packager-ts": "^2.9.3",
"@parcel/transformer-typescript-tsc": "^2.9.3",
"@parcel/transformer-typescript-types": "^2.9.3",
"@semantic-release/changelog": "^6.0.1",
"@semantic-release/git": "^10.0.1",
"@swc/core": "^1.3.27",
"@swc/jest": "^0.2.24",
"@types/jasmine": "^5.0.0",
"@wdio/browserstack-service": "^8.11.2",
"@wdio/cli": "^8.11.2",
"@wdio/globals": "^8.11.2",
"@wdio/jasmine-framework": "^8.11.2",
"@wdio/local-runner": "^8.11.2",
"@wdio/spec-reporter": "^8.11.2",
"@wdio/types": "^8.10.4",
"http-server": "^14.1.1",
"jest": "^29.3.1",
"jest-environment-jsdom": "^29.3.1",
"mock-socket": "^9.0.0",
"parcel": "^2.9.3",
"prettier": "^3.0.0",
"semantic-release": "^23.0.0",
"ts-node": "^10.9.1",
"typescript": "^5.0.0",
"wdio-geckodriver-service": "^5.0.1"
},
"dependencies": {
"@msgpack/msgpack": "^2.8.0",
"eventemitter3": "^4.0.7",
"peerjs-js-binarypack": "^2.1.0",
"webrtc-adapter": "^9.0.0"
},
"alias": {
"process": false,
"buffer": false
}
}